mdt-client 1.1.0 → 1.3.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/dist/index.d.ts +1 -0
- package/dist/tsconfig.tsbuildinfo +2715 -1
- package/package.json +5 -2
- package/readme.md +15 -15
- package/types/common/Datasource.d.ts +1 -1
- package/types/common/Field.d.ts +4 -3
- package/types/components/baseFormControls/input/inputView.d.ts +3 -0
- package/types/components/icon/iconOptions.d.ts +8 -2
- package/types/data/active/ActivationListAdapterTypes.d.ts +6 -0
- package/types/helpers/types.d.ts +7 -3
- package/types/helpers/ui/elementModificators/focusableComponent.d.ts +2 -0
- package/types/helpers/ui/keyboardUtils/keyboardUtils.d.ts +3 -3
- package/types/helpers/zone/IZone.d.ts +2 -0
- package/types/security/PermissionLevel.d.ts +2 -1
- package/types/services/IFilter.d.ts +1 -0
- package/types/services/customModules/facades/Form/IFormControlFacade.d.ts +3 -1
- package/types/services/customModules/facades/Form/IFormFacade.d.ts +7 -3
- package/types/services/customModules/facades/IMdtFacade.d.ts +2 -0
- package/types/services/customModules/facades/List/IListControlFacade.d.ts +3 -1
- package/types/services/customModules/facades/components/ModalFacade.d.ts +4 -0
- package/types/services/customModules/facades/schema/IObjectFacade.d.ts +2 -0
- package/types/services/customModules/facades/services/CommandManagerFacade.d.ts +3 -1
- package/types/services/customModules/facades/utils/IUiComponentsFacade.d.ts +4 -1
- package/types/services/customModules/facades/utils/IUiFacade.d.ts +6 -1
- package/types/services/customModules/facades/utils/ImUtilsFacade.d.ts +2 -0
- package/types/services/dropdown/IDropDownMenu.d.ts +4 -0
- package/types/views/form/controls/commonControl/ICommonControl.d.ts +2 -0
- package/types/views/list/IListView.d.ts +2 -0
- package/types/views/list/schema/ListPageOptions.schema.d.ts +11 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mdt-client",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"types-update": "tsc --project tsconfig.facade-types.json",
|
|
14
14
|
"update": "tsc --project tsconfig.facade-types.json && tsc",
|
|
15
15
|
"pub-patch": "npm version patch && npm publish",
|
|
16
|
-
"pub-minor": "npm version
|
|
16
|
+
"pub-minor": "npm version minor && npm publish"
|
|
17
17
|
},
|
|
18
18
|
"repository": {
|
|
19
19
|
"type": "git",
|
|
@@ -23,5 +23,8 @@
|
|
|
23
23
|
"license": "ISC",
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"typescript": "^4.2.3"
|
|
26
|
+
},
|
|
27
|
+
"dependencies": {
|
|
28
|
+
"@types/mithril": "^0.0.27"
|
|
26
29
|
}
|
|
27
30
|
}
|
package/readme.md
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
### Установка
|
|
2
|
-
|
|
3
|
-
Установка с помощью `npm`
|
|
4
|
-
|
|
5
|
-
```
|
|
6
|
-
npm install mdt-client
|
|
7
|
-
```
|
|
8
|
-
|
|
9
|
-
### Использование
|
|
10
|
-
|
|
11
|
-
Для использования нужно импортировать нужный компонент
|
|
12
|
-
|
|
13
|
-
```js
|
|
14
|
-
import { Navigation } from "mdt-client";
|
|
15
|
-
```
|
|
1
|
+
### Установка
|
|
2
|
+
|
|
3
|
+
Установка с помощью `npm`
|
|
4
|
+
|
|
5
|
+
```
|
|
6
|
+
npm install mdt-client
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
### Использование
|
|
10
|
+
|
|
11
|
+
Для использования нужно импортировать нужный компонент
|
|
12
|
+
|
|
13
|
+
```js
|
|
14
|
+
import { Navigation } from "mdt-client";
|
|
15
|
+
```
|
|
@@ -3,7 +3,7 @@ import { Query } from "../services/api/Query";
|
|
|
3
3
|
import { ApiRequestOptions } from "../services/api/ApiRequestOptions";
|
|
4
4
|
export interface Datasource {
|
|
5
5
|
fetch(query: Query, table: Table, options?: ApiRequestOptions, batch?: boolean): any;
|
|
6
|
-
save?(data: any, params?: any, options?: ApiRequestOptions): any
|
|
6
|
+
save?(data: any, params?: any, options?: ApiRequestOptions): PromiseLike<any>;
|
|
7
7
|
delete?(ids: any[], table: Table): any;
|
|
8
8
|
table?: Table;
|
|
9
9
|
}
|
package/types/common/Field.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { FieldCode } from "mdtScripts/helpers/types";
|
|
1
|
+
import { FieldCode, FieldKind, Valued } from "mdtScripts/helpers/types";
|
|
2
|
+
import { IFilter } from "mdtServices/IFilter";
|
|
2
3
|
import { Record } from "./Record";
|
|
3
4
|
import { Table } from "./Table";
|
|
4
5
|
export interface Field extends Record {
|
|
@@ -18,7 +19,7 @@ export interface Field extends Record {
|
|
|
18
19
|
hidden?: boolean;
|
|
19
20
|
id_RefObject?: number;
|
|
20
21
|
id_RefObjectField?: number;
|
|
21
|
-
kind?:
|
|
22
|
+
kind?: FieldKind;
|
|
22
23
|
role?: string;
|
|
23
24
|
length?: number;
|
|
24
25
|
hasDefault?: boolean;
|
|
@@ -29,7 +30,7 @@ export interface Field extends Record {
|
|
|
29
30
|
refTable?: Table;
|
|
30
31
|
readonly?: boolean;
|
|
31
32
|
multiple?: boolean;
|
|
32
|
-
refFilter?:
|
|
33
|
+
refFilter?: Valued<IFilter>;
|
|
33
34
|
validate?: Function;
|
|
34
35
|
min?: number;
|
|
35
36
|
max?: number;
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/// <reference types="../../../../mithril" />
|
|
2
|
+
/// <reference types="mithril" />
|
|
1
3
|
import "./inputView.less";
|
|
2
4
|
import { ComponentSize } from "mdtScripts/helpers/utils/stringifyControlSize";
|
|
3
5
|
import { KeyboardActions } from "mdtScripts/helpers/ui/elementModificators/focusableComponent";
|
|
@@ -17,6 +19,7 @@ export interface InputOptions {
|
|
|
17
19
|
hasError?: boolean;
|
|
18
20
|
keyboardActions?: KeyboardActions;
|
|
19
21
|
className?: CSSClassName;
|
|
22
|
+
onCreated?: (el: HTMLInputElement) => void;
|
|
20
23
|
/**
|
|
21
24
|
*
|
|
22
25
|
* @deprecated
|
|
@@ -1,7 +1,13 @@
|
|
|
1
|
+
/// <reference types="../../../../mithril" />
|
|
2
|
+
/// <reference types="mithril" />
|
|
3
|
+
import { CSSClassName } from "mdtScripts/helpers/types";
|
|
1
4
|
import { FormattedText } from "../../helpers/formattedText";
|
|
2
5
|
export declare type Icon = string;
|
|
3
|
-
export interface
|
|
6
|
+
export interface BaseIconOptions {
|
|
4
7
|
size?: "2xs" | "xs" | "sm" | "lg" | "xl" | "2xl" | "1x" | "2x" | "3x" | "4x" | "5x" | "6x" | "7x" | "8x" | "9x" | "10x";
|
|
8
|
+
className?: CSSClassName;
|
|
9
|
+
}
|
|
10
|
+
export interface IconOptions extends BaseIconOptions {
|
|
5
11
|
fixedWidth?: boolean;
|
|
6
12
|
rotate?: "90" | "180" | "270";
|
|
7
13
|
flip?: "horizontal" | "vertical" | "both";
|
|
@@ -10,7 +16,7 @@ export interface IconOptions {
|
|
|
10
16
|
attrs?: _mithril.MithrilAttributes;
|
|
11
17
|
title?: string;
|
|
12
18
|
tooltip?: FormattedText;
|
|
13
|
-
className?: string;
|
|
14
19
|
onmousedown?: () => void;
|
|
15
20
|
onclick?: (e?: MouseEvent) => void;
|
|
16
21
|
}
|
|
22
|
+
export declare type IconElOptions = BaseIconOptions;
|
package/types/helpers/types.d.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/// <reference types="../../../../mithril" />
|
|
2
|
+
/// <reference types="mithril" />
|
|
1
3
|
export interface AnyObject {
|
|
2
4
|
[key: string]: any;
|
|
3
5
|
}
|
|
@@ -9,14 +11,15 @@ declare type CSSSizeUnit = string;
|
|
|
9
11
|
export declare type NotifierType = "log" | "error" | "warn" | "info" | "success";
|
|
10
12
|
export interface NotifierOptions {
|
|
11
13
|
type?: NotifierType;
|
|
12
|
-
msg?:
|
|
14
|
+
msg?: MessageText;
|
|
13
15
|
icon?: string;
|
|
14
16
|
}
|
|
15
17
|
export interface Notifier {
|
|
16
|
-
notify(title:
|
|
18
|
+
notify(title: MessageText, options?: NotifierOptions): void;
|
|
17
19
|
}
|
|
18
20
|
export declare type ViewElement = _mithril.MithrilVirtualElement | _mithril.MithrilVirtualElement[] | string;
|
|
19
21
|
export declare type CommandEvent = Event | _mithril.MithrilEvent;
|
|
22
|
+
export declare type InputChangeEvent = Event | _mithril.MithrilEvent;
|
|
20
23
|
export declare type CSSClassName = string;
|
|
21
24
|
export declare type MithrilControl = ViewControl | ContentControl;
|
|
22
25
|
export interface ViewControl {
|
|
@@ -28,6 +31,7 @@ export interface ContentControl {
|
|
|
28
31
|
[key: string]: any;
|
|
29
32
|
}
|
|
30
33
|
export declare type Markdown = string;
|
|
34
|
+
export declare type MessageText = Markdown | string;
|
|
31
35
|
export declare type ColorStyle = "default" | "primary" | "success" | "info" | "warning" | "danger" | "fatal";
|
|
32
36
|
export declare type ButtonStyle = ColorStyle;
|
|
33
37
|
export declare type ObjectCode = string;
|
|
@@ -45,9 +49,9 @@ export declare type MithrilAttributes = _mithril.MithrilAttributes & {
|
|
|
45
49
|
};
|
|
46
50
|
export declare type AnyError = any;
|
|
47
51
|
export declare type FieldPath = string;
|
|
48
|
-
export declare type FieldLogicTypeCode = string;
|
|
49
52
|
export declare type FieldId = number;
|
|
50
53
|
export declare type FieldCode = string;
|
|
54
|
+
export declare type FieldKind = "dfk" | "o2m" | "o2o" | "hist" | "dfk-list";
|
|
51
55
|
export declare type KeyboardKeyCode = string;
|
|
52
56
|
export declare type LanguageCode = "ru" | "en";
|
|
53
57
|
export declare type LanguageId = number;
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/// <reference types="../../../../mithril" />
|
|
2
|
+
/// <reference types="mithril" />
|
|
1
3
|
import { ComponentConfigParams } from "./modificatorsTypes";
|
|
2
4
|
export declare function getFocusableComponentAttrs(): _mithril.MithrilAttributes;
|
|
3
5
|
declare type KeyboardAction = (e: KeyboardEvent) => void;
|
|
@@ -5,10 +5,10 @@ interface EventModifierKeys {
|
|
|
5
5
|
alt: boolean;
|
|
6
6
|
ctrl: boolean;
|
|
7
7
|
}
|
|
8
|
-
declare type
|
|
9
|
-
export declare function checkKeydownModifiers(e: KeyboardEvent, pressedModifierKeys?:
|
|
8
|
+
export declare type EventModifierKey = keyof EventModifierKeys;
|
|
9
|
+
export declare function checkKeydownModifiers(e: KeyboardEvent, pressedModifierKeys?: EventModifierKey[]): boolean;
|
|
10
10
|
interface KeydownEventKeyCheckingOptions {
|
|
11
|
-
requiredModifiers?:
|
|
11
|
+
requiredModifiers?: EventModifierKey[];
|
|
12
12
|
/** @default true */
|
|
13
13
|
checkModifiers?: boolean;
|
|
14
14
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { IFilterGroup } from "mdtServices/IFilter";
|
|
1
2
|
import { MdtField } from "../common/MdtField";
|
|
2
3
|
import { MdtObject } from "../common/MdtObject";
|
|
3
4
|
import { Record } from "../common/Record";
|
|
@@ -20,7 +21,7 @@ export interface PrincipalPermission extends Record {
|
|
|
20
21
|
ID_Field$?: MdtField;
|
|
21
22
|
LevelGrant?: PermissionLevel;
|
|
22
23
|
LevelDeny?: PermissionLevel;
|
|
23
|
-
Filter?:
|
|
24
|
+
Filter?: IFilterGroup;
|
|
24
25
|
}
|
|
25
26
|
export interface Permission extends Record {
|
|
26
27
|
id?: number;
|
|
@@ -64,6 +64,7 @@ export interface FilterConstructor {
|
|
|
64
64
|
queryIn(field: any, table: any, subField: any, filter: any, args?: any): IFilterIn;
|
|
65
65
|
cast(filter: any, cast: any): IFilter;
|
|
66
66
|
equalTemplate(p1: any, p2: any): any;
|
|
67
|
+
empty: any;
|
|
67
68
|
}
|
|
68
69
|
export declare class Filter {
|
|
69
70
|
static empty: IFilter;
|
|
@@ -50,7 +50,7 @@ export interface IFormControlFacade extends ParentCtrl {
|
|
|
50
50
|
/** Установить флаг доступности редактирования формы */
|
|
51
51
|
setReadonly(readonly: boolean): void;
|
|
52
52
|
/** Изменить свойства существующей кнопки */
|
|
53
|
-
updateCommand(findCondition: () => boolean, command: Partial<ButtonFacade>): void;
|
|
53
|
+
updateCommand(findCondition: (button: ButtonFacade) => boolean, command: Partial<ButtonFacade>): void;
|
|
54
54
|
/** Повторно инициализировать форму */
|
|
55
55
|
reinit(): void;
|
|
56
56
|
/** Сохранить форму */
|
|
@@ -61,4 +61,6 @@ export interface IFormControlFacade extends ParentCtrl {
|
|
|
61
61
|
getZones(): FormZones;
|
|
62
62
|
/** Подписаться на событие обновление значения поля формы */
|
|
63
63
|
onUpdated<V = string>(callback: (field: IFieldFacade, value: V) => void): void;
|
|
64
|
+
/** Закрыть форму */
|
|
65
|
+
close(): void;
|
|
64
66
|
}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { MdtRecord } from "mdtScripts/common/Record";
|
|
2
|
+
import { FormattedText } from "mdtScripts/helpers/formattedText";
|
|
3
|
+
import { Valued } from "mdtScripts/helpers/types";
|
|
2
4
|
import { Field } from "../../../../common/Field";
|
|
3
5
|
import { IButton } from "../../../../views/form/controls/monacoEditor/jsonSchemas/Button.schema";
|
|
4
6
|
import { RecordId } from "../utils/IApiFacade";
|
|
5
7
|
import { IFormControlFacade } from "./IFormControlFacade";
|
|
6
8
|
export declare type ActionButton = IButton & {
|
|
7
9
|
/** Всплывающая подсказка */
|
|
8
|
-
description?:
|
|
9
|
-
(): string;
|
|
10
|
-
};
|
|
10
|
+
description?: Valued<FormattedText>;
|
|
11
11
|
/** Подписка на событие нажатия на кнопку */
|
|
12
12
|
execute?: () => void;
|
|
13
13
|
/** Активность кнопки */
|
|
@@ -56,6 +56,10 @@ export interface IFormServiceFacade {
|
|
|
56
56
|
onCreated(callback: (form: IFormControlFacade) => void): void;
|
|
57
57
|
/** Добавить настройки для полей формы */
|
|
58
58
|
addFieldOptions(tableCode: string, options: IFormInitOptions): void;
|
|
59
|
+
/** Зарегистрировать расширение формы
|
|
60
|
+
* @param {string} alias - Имя свойства, которое можно использовать для установки опций экстендера
|
|
61
|
+
*/
|
|
62
|
+
registerExtender<T>(extender: IFormExtenderFacade<T>, alias: string): void;
|
|
59
63
|
}
|
|
60
64
|
export interface ICustomField extends Field {
|
|
61
65
|
/** Опции контрола поля */
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/// <reference types="../../../../mithril" />
|
|
2
|
+
/// <reference types="mithril" />
|
|
1
3
|
import { FilterConstructor } from "../../../services/IFilter";
|
|
2
4
|
import { IFieldControlFacadeContstructor } from "./Form/IFieldControlFacade";
|
|
3
5
|
import { IFieldControlManagerFacade } from "./Form/IFieldControlManagerFacade";
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/// <reference types="../../../../mithril" />
|
|
2
|
+
/// <reference types="mithril" />
|
|
1
3
|
import { FilterSetterOptions, IFilter } from "../../../../services/IFilter";
|
|
2
4
|
import { ButtonFacade } from "../Form/IFormFacade";
|
|
3
5
|
import { ParentCtrl } from "../utils/IUiFacade";
|
|
@@ -32,7 +34,7 @@ export interface IListControlFacade extends ParentCtrl {
|
|
|
32
34
|
/** Установить расширения списка */
|
|
33
35
|
setExtOptions(extOptions: any): void;
|
|
34
36
|
/** Изменить свойства существующей кнопки */
|
|
35
|
-
updateCommand(findCondition: () => boolean, command: Partial<ButtonFacade>): void;
|
|
37
|
+
updateCommand(findCondition: (button: ButtonFacade) => boolean, command: Partial<ButtonFacade>): void;
|
|
36
38
|
/** Открыть форму добавления записи */
|
|
37
39
|
openNewRecordForm(): void;
|
|
38
40
|
/** Удалить выделенные строки */
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ObjectId } from "mdtScripts/helpers/types";
|
|
1
2
|
import { IFieldFacade } from "./IFieldFacade";
|
|
2
3
|
export interface IObjectFacade {
|
|
3
4
|
getCode(): string;
|
|
@@ -6,4 +7,5 @@ export interface IObjectFacade {
|
|
|
6
7
|
getPrimaryField(): IFieldFacade;
|
|
7
8
|
isReadonly(): boolean;
|
|
8
9
|
getField(code: string, check?: boolean): IFieldFacade;
|
|
10
|
+
getId(): ObjectId;
|
|
9
11
|
}
|
|
@@ -5,5 +5,7 @@ export declare class CommandManagerFacade {
|
|
|
5
5
|
/** Добавить группу команд */
|
|
6
6
|
addGroup(group: CommandGroupProps): CommandGroup<CommandManagerContext>;
|
|
7
7
|
/** Добавить команды */
|
|
8
|
-
addCommands(commands: CommandBase<CommandManagerContext>[]): void;
|
|
8
|
+
addCommands(commands: CommandBase<CommandManagerContext>[], groupCode?: string): void;
|
|
9
|
+
/** Получить существующую команду */
|
|
10
|
+
getCommand(code: string): import("../../../commands/Command").Command<CommandManagerContext>;
|
|
9
11
|
}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
/// <reference types="../../../../mithril" />
|
|
2
|
+
/// <reference types="mithril" />
|
|
1
3
|
import { ProcessPrincipalsListItem } from "../../../../components/processPrincipalsList/ProcessPrincipalsListItem";
|
|
2
4
|
import { Markdown, MithrilAttributes, Valued, ViewElement } from "../../../../helpers/types";
|
|
3
|
-
import { Icon, IconOptions } from "../../../../components/icon/iconOptions";
|
|
5
|
+
import { Icon, IconElOptions, IconOptions } from "../../../../components/icon/iconOptions";
|
|
4
6
|
import { InputOptions } from "../../../../components/baseFormControls/input/inputView";
|
|
5
7
|
import { CommonControlOptions } from "../../../../views/form/controls/commonControl/ICommonControl";
|
|
6
8
|
import { ButtonFacade } from "../Form/IFormFacade";
|
|
@@ -10,6 +12,7 @@ export interface IUiComponentsFacade {
|
|
|
10
12
|
button(button: ButtonFacade, translate?: boolean): ViewElement;
|
|
11
13
|
topNavButton(options: TopNavButton): _mithril.MithrilVirtualElement;
|
|
12
14
|
icon(code: string, options?: IconOptions): _mithril.MithrilVirtualElement;
|
|
15
|
+
iconHTML(icon: Icon, options?: IconElOptions): HTMLElement;
|
|
13
16
|
processFormBlock(options: IProcessFormBlockOptions): _mithril.MithrilVirtualElement;
|
|
14
17
|
commonControl(options: CommonControlOptions): _mithril.MithrilVirtualElement;
|
|
15
18
|
unstyledInput(options: InputOptions): _mithril.MithrilVirtualElement;
|
|
@@ -1,7 +1,10 @@
|
|
|
1
|
+
/// <reference types="../../../../mithril" />
|
|
2
|
+
/// <reference types="mithril" />
|
|
1
3
|
import { MithrilControl } from "../../../../helpers/types";
|
|
2
4
|
import { DropdownOptions } from "../../../dropdown/IDropDownMenu";
|
|
3
5
|
import { ButtonFacade } from "../Form/IFormFacade";
|
|
4
6
|
import { DropdownTargetContext, IDropdownMenu } from "mdtServices/dropdown/IDropDownMenu";
|
|
7
|
+
import { IModalFacade } from "../components/ModalFacade";
|
|
5
8
|
export declare type onModalResizeCallback = (data: IModalSizingState) => void;
|
|
6
9
|
export interface IType<T> {
|
|
7
10
|
new (...args: any[]): T;
|
|
@@ -25,7 +28,7 @@ export interface IUiFacade {
|
|
|
25
28
|
/** Вызвать окно уведомления */
|
|
26
29
|
showNotification(msg: CustomNotification, duration?: number): any;
|
|
27
30
|
/** Вызвать модальное окно */
|
|
28
|
-
showModal(ctrl: MithrilControl | ParentCtrl, options?: IModalOptions):
|
|
31
|
+
showModal(ctrl: MithrilControl | ParentCtrl, options?: IModalOptions): IModalFacade;
|
|
29
32
|
/** Вызвать боковую панель */
|
|
30
33
|
showSidebar(ctrl: MithrilControl | ParentCtrl, options?: IPanelOptions): any;
|
|
31
34
|
/** Создать выпадающее меню */
|
|
@@ -53,6 +56,8 @@ export interface IModalOptions {
|
|
|
53
56
|
initialSizingState?: IModalSizingState;
|
|
54
57
|
/** Тип модального окна */
|
|
55
58
|
type?: ModalTypes;
|
|
59
|
+
/** Дополнительные кнопки на окне */
|
|
60
|
+
buttons?: ButtonFacade[];
|
|
56
61
|
}
|
|
57
62
|
export interface IPanelOptions {
|
|
58
63
|
/** Отображать боковую панель в расширенном на весь экран виде */
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/// <reference types="../../../../mithril" />
|
|
2
|
+
/// <reference types="mithril" />
|
|
1
3
|
import { MithrilControl } from "mdtScripts/helpers/types";
|
|
2
4
|
export declare type ConfigFunction = (element: HTMLElement, isInitialized: boolean, context?: any) => void;
|
|
3
5
|
export interface ImUtilsFacade {
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/// <reference types="../../../../mithril" />
|
|
2
|
+
/// <reference types="mithril" />
|
|
1
3
|
import { MithrilContext, MithrilControl } from "../../helpers/types";
|
|
2
4
|
export declare class IDropdownMenu<I> {
|
|
3
5
|
constructor(items: I[], uid: string, options?: DropdownOptions<I>);
|
|
@@ -13,12 +15,14 @@ export interface DropdownOptions<I> {
|
|
|
13
15
|
class?: string;
|
|
14
16
|
onShow?: () => void;
|
|
15
17
|
onClose?: () => void;
|
|
18
|
+
wrapAttrs?: _mithril.MithrilAttributes;
|
|
16
19
|
}
|
|
17
20
|
export interface DropdownMenuViewOptions<I> {
|
|
18
21
|
items: I[];
|
|
19
22
|
itemView?: (item: Exclude<I, MithrilControl>) => _mithril.MithrilVirtualElement;
|
|
20
23
|
onSelect: (item: Exclude<I, MithrilControl>) => void;
|
|
21
24
|
class?: string;
|
|
25
|
+
wrapAttrs?: _mithril.MithrilAttributes;
|
|
22
26
|
}
|
|
23
27
|
export declare type DropdownTargetContext<I> = MithrilContext<{
|
|
24
28
|
$dropdown?: IDropdownMenu<I>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ActivationListAdapterOptions } from "mdtScripts/data/active/ActivationListAdapterTypes";
|
|
1
2
|
import { BaseQuery } from "../../../services/api/BaseQuery";
|
|
2
3
|
import { QuerySorting } from "../../../services/api/Query";
|
|
3
4
|
import { IFilter } from "../../../services/IFilter";
|
|
@@ -75,5 +76,15 @@ export interface ListPageOptions {
|
|
|
75
76
|
* inherit - наследует значение родителя
|
|
76
77
|
* */
|
|
77
78
|
whiteSpaceHeader?: WhiteSpaceType;
|
|
79
|
+
/**
|
|
80
|
+
* Управление активностью записей
|
|
81
|
+
*/
|
|
82
|
+
activation?: ActivationListAdapterOptions;
|
|
83
|
+
/**
|
|
84
|
+
* Отключить фиксацию таблицы при прокрутке
|
|
85
|
+
* @TJS-type boolean
|
|
86
|
+
* @TJS-enum [true]
|
|
87
|
+
*/
|
|
88
|
+
disableFixOnScroll?: boolean;
|
|
78
89
|
}
|
|
79
90
|
export {};
|