@matreshka/bff 0.25.1 → 0.26.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/components/aliases/button.js +1 -1
- package/dist/components/aliases/column.js +1 -1
- package/dist/components/aliases/row.js +1 -1
- package/dist/components/app.d.ts +1 -1
- package/dist/components/app.js +1 -1
- package/dist/components/board.d.ts +4 -4
- package/dist/components/board.js +6 -6
- package/dist/components/boot.js +1 -1
- package/dist/components/camera.d.ts +5 -5
- package/dist/components/camera.js +3 -3
- package/dist/components/charts/chart.d.ts +3 -3
- package/dist/components/charts/chart.js +2 -2
- package/dist/components/component.d.ts +10 -10
- package/dist/components/component.js +1 -1
- package/dist/components/container.d.ts +2 -2
- package/dist/components/container.js +1 -1
- package/dist/components/dialog.d.ts +4 -4
- package/dist/components/dialog.js +2 -2
- package/dist/components/entry-component.d.ts +1 -1
- package/dist/components/entry-component.js +1 -1
- package/dist/components/enum/password-input-kind.d.ts +1 -1
- package/dist/components/enum/password-input-kind.js +1 -1
- package/dist/components/enum/popover-position-area.d.ts +1 -1
- package/dist/components/enum/popover-position-area.js +1 -1
- package/dist/components/enum/scroll-to-position.d.ts +1 -1
- package/dist/components/enum/scroll-to-position.js +1 -1
- package/dist/components/enum/text-input-kind.d.ts +1 -1
- package/dist/components/enum/text-input-kind.js +1 -1
- package/dist/components/enum/textarea-resize.d.ts +1 -1
- package/dist/components/enum/textarea-resize.js +1 -1
- package/dist/components/file-upload-area.d.ts +2 -2
- package/dist/components/file-upload-area.js +19 -19
- package/dist/components/for-each.d.ts +2 -2
- package/dist/components/for-each.js +4 -4
- package/dist/components/form.d.ts +2 -2
- package/dist/components/form.js +1 -1
- package/dist/components/grid.d.ts +6 -6
- package/dist/components/grid.js +2 -2
- package/dist/components/index.d.ts +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/inputs/number-input.d.ts +1 -1
- package/dist/components/inputs/number-input.js +1 -1
- package/dist/components/inputs/password-input.d.ts +2 -2
- package/dist/components/inputs/password-input.js +1 -1
- package/dist/components/inputs/text-editor.d.ts +1 -1
- package/dist/components/inputs/text-editor.js +15 -15
- package/dist/components/inputs/text-input.d.ts +2 -2
- package/dist/components/inputs/text-input.js +1 -1
- package/dist/components/inputs/textarea.d.ts +2 -2
- package/dist/components/inputs/textarea.js +1 -1
- package/dist/components/item-list/flatten-nested-items.d.ts +1 -1
- package/dist/components/item-list/item-list-host.d.ts +1 -1
- package/dist/components/item-list/item-list.d.ts +1 -1
- package/dist/components/item-list/list-from-ref-context.js +2 -2
- package/dist/components/item-list/nested-items-host-support.js +1 -1
- package/dist/components/line.d.ts +1 -1
- package/dist/components/line.js +1 -1
- package/dist/components/map.d.ts +6 -6
- package/dist/components/map.js +6 -6
- package/dist/components/outputs/currency.d.ts +1 -1
- package/dist/components/outputs/currency.js +1 -1
- package/dist/components/outputs/datetime.d.ts +1 -1
- package/dist/components/outputs/datetime.js +1 -1
- package/dist/components/outputs/icon.d.ts +1 -1
- package/dist/components/outputs/icon.js +1 -1
- package/dist/components/outputs/iframe.d.ts +3 -3
- package/dist/components/outputs/iframe.js +2 -2
- package/dist/components/outputs/image.d.ts +6 -6
- package/dist/components/outputs/image.js +4 -4
- package/dist/components/outputs/number.d.ts +1 -1
- package/dist/components/outputs/number.js +1 -1
- package/dist/components/outputs/progress-bar.d.ts +1 -1
- package/dist/components/outputs/progress-bar.js +1 -1
- package/dist/components/outputs/progress-spinner.d.ts +1 -1
- package/dist/components/outputs/progress-spinner.js +1 -1
- package/dist/components/outputs/qr-code.d.ts +1 -1
- package/dist/components/outputs/qr-code.js +1 -1
- package/dist/components/outputs/text.d.ts +5 -5
- package/dist/components/outputs/text.js +7 -7
- package/dist/components/outputs/vector.d.ts +7 -7
- package/dist/components/outputs/vector.js +6 -6
- package/dist/components/page.d.ts +3 -3
- package/dist/components/page.js +1 -1
- package/dist/components/popover.d.ts +2 -2
- package/dist/components/popover.js +2 -2
- package/dist/components/stack.d.ts +25 -25
- package/dist/components/stack.js +10 -10
- package/dist/components/types/container-overlay.d.ts +1 -1
- package/dist/components/utils/targeted-client-component-action.d.ts +1 -1
- package/dist/components/webmcp/web-mcp-tool.d.ts +4 -4
- package/dist/components/webmcp/web-mcp-tool.js +10 -7
- package/dist/core/actions/action.d.ts +1 -1
- package/dist/core/actions/animate-component.d.ts +6 -6
- package/dist/core/actions/animate-component.js +3 -3
- package/dist/core/actions/component-local-actions.d.ts +2 -2
- package/dist/core/actions/set-context.d.ts +1 -1
- package/dist/core/boot.js +1 -1
- package/dist/core/client-storage.js +2 -2
- package/dist/core/client.d.ts +10 -9
- package/dist/core/client.js +32 -31
- package/dist/core/conditions/condition-group.d.ts +1 -1
- package/dist/core/conditions/condition-group.js +2 -2
- package/dist/core/conditions/condition-operand.d.ts +2 -2
- package/dist/core/conditions/condition.d.ts +2 -2
- package/dist/core/conditions/context-array-includes.js +1 -1
- package/dist/core/conditions/context-array-length.d.ts +1 -1
- package/dist/core/conditions/context-array-length.js +2 -2
- package/dist/core/conditions/context-value-defined.d.ts +9 -3
- package/dist/core/conditions/context-value-defined.js +7 -1
- package/dist/core/conditions/context-value-equal.js +1 -1
- package/dist/core/conditions/context-value-in.js +1 -1
- package/dist/core/conditions/context-value-not-equal.js +1 -1
- package/dist/core/conditions/context-value-undefined.d.ts +9 -3
- package/dist/core/conditions/context-value-undefined.js +7 -1
- package/dist/core/conditions/desktop-device.js +1 -1
- package/dist/core/conditions/mobile-device.js +1 -1
- package/dist/core/conditions/not-desktop-device.js +1 -1
- package/dist/core/conditions/not-mobile-device.js +1 -1
- package/dist/core/conditions/not-tablet-device.js +1 -1
- package/dist/core/conditions/tablet-device.js +1 -1
- package/dist/core/context/context-ref.d.ts +1 -1
- package/dist/core/context/context.d.ts +2 -2
- package/dist/core/context/context.js +7 -7
- package/dist/core/gateway-connection.js +8 -8
- package/dist/core/index.d.ts +2 -2
- package/dist/core/index.js +1 -1
- package/dist/core/local/index.d.ts +2 -2
- package/dist/core/local/index.js +1 -1
- package/dist/core/matreshka.js +2 -2
- package/dist/core/types/client-settings.d.ts +3 -3
- package/dist/core/types/componentable.d.ts +2 -2
- package/dist/core/types/pageable.d.ts +1 -1
- package/dist/core/utils/color-roles-to-ids.d.ts +2 -2
- package/dist/core/utils/color-token-id.d.ts +1 -1
- package/dist/core/utils/deep-pick.d.ts +1 -1
- package/dist/core/utils/deep-pick.js +3 -3
- package/dist/core/utils/replace-context-keys.d.ts +3 -3
- package/dist/core/utils/replace-context-keys.js +6 -67
- package/dist/core/utils/serialize-client-settings-colors-for-handshake.d.ts +2 -2
- package/dist/core/utils/serialize-component-tree.d.ts +2 -2
- package/dist/core/utils/targeted-client-action.d.ts +1 -1
- package/dist/core/utils/targeted-client-action.js +8 -7
- package/dist/platforms/browser-platform.js +27 -27
- package/dist/platforms/max-mini-app-platform.d.ts +1 -1
- package/dist/platforms/max-mini-app-platform.js +5 -5
- package/dist/platforms/mobile-platform.d.ts +2 -2
- package/dist/platforms/mobile-platform.js +42 -42
- package/dist/platforms/platform.d.ts +1 -1
- package/dist/platforms/platform.js +21 -21
- package/dist/platforms/telegram-mini-app-platform.d.ts +1 -1
- package/dist/platforms/telegram-mini-app-platform.js +23 -23
- package/dist/platforms/utils/client-back-platform-action.js +1 -1
- package/dist/platforms/utils/client-navigate-platform-action.js +1 -1
- package/dist/platforms/utils/client-platform.js +1 -1
- package/dist/platforms/utils/client-reload-platform-action.js +1 -1
- package/dist/platforms/utils/client-route-page-wait.d.ts +1 -1
- package/dist/platforms/utils/client-route-page-wait.js +2 -2
- package/dist/platforms/utils/mobile-ble-services.d.ts +2 -2
- package/dist/platforms/utils/mobile-ble-services.js +19 -19
- package/dist/platforms/utils/targeted-client-platform-action.d.ts +2 -2
- package/dist/platforms/utils/targeted-client-platform-stream.d.ts +2 -2
- package/dist/platforms/utils/targeted-client-platform-stream.js +8 -7
- package/package.json +5 -3
- package/dist/core/utils/hex-to-hsl.d.ts +0 -14
- package/dist/core/utils/hex-to-hsl.js +0 -49
- package/dist/core/utils/merge-deep.d.ts +0 -8
- package/dist/core/utils/merge-deep.js +0 -39
- package/dist/core/utils/parse-context-path.d.ts +0 -4
- package/dist/core/utils/parse-context-path.js +0 -16
- package/dist/core/utils/set-object-property.d.ts +0 -2
- package/dist/core/utils/set-object-property.js +0 -29
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Button = void 0;
|
|
4
4
|
exports.button = button;
|
|
5
|
-
const stack_direction_1 = require("@matreshka/
|
|
5
|
+
const stack_direction_1 = require("@matreshka/client-bff-protocol/enums/stack-direction");
|
|
6
6
|
const component_tree_node_1 = require("../../core/types/component-tree-node");
|
|
7
7
|
const stack_1 = require("../stack");
|
|
8
8
|
const defaultButtonAlign = {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Column = void 0;
|
|
4
4
|
exports.column = column;
|
|
5
|
-
const stack_direction_1 = require("@matreshka/
|
|
5
|
+
const stack_direction_1 = require("@matreshka/client-bff-protocol/enums/stack-direction");
|
|
6
6
|
const stack_1 = require("../stack");
|
|
7
7
|
function column(arg0, arg1) {
|
|
8
8
|
if (arg1 !== undefined) {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Row = void 0;
|
|
4
4
|
exports.row = row;
|
|
5
|
-
const stack_direction_1 = require("@matreshka/
|
|
5
|
+
const stack_direction_1 = require("@matreshka/client-bff-protocol/enums/stack-direction");
|
|
6
6
|
const stack_1 = require("../stack");
|
|
7
7
|
function row(arg0, arg1) {
|
|
8
8
|
if (arg1 !== undefined) {
|
package/dist/components/app.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ServerComponentClass } from "@matreshka/
|
|
1
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
2
2
|
import { EntryComponent } from "./entry-component";
|
|
3
3
|
export declare class App extends EntryComponent {
|
|
4
4
|
class(): ServerComponentClass;
|
package/dist/components/app.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.App = void 0;
|
|
4
|
-
const server_component_class_1 = require("@matreshka/
|
|
4
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
5
5
|
const entry_component_1 = require("./entry-component");
|
|
6
6
|
// Класс-заглушка: entry-корень для глобальных App-оверлеев.
|
|
7
7
|
class App extends entry_component_1.EntryComponent {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ServerComponentClass } from "@matreshka/
|
|
2
|
-
import type { BoardConfig, BoardPoint } from "@matreshka/
|
|
3
|
-
import { type FlexItemSpec } from "@matreshka/
|
|
4
|
-
import type { NestedItemBase } from "@matreshka/
|
|
1
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
2
|
+
import type { BoardConfig, BoardPoint } from "@matreshka/client-bff-protocol/types/board-config";
|
|
3
|
+
import { type FlexItemSpec } from "@matreshka/client-bff-protocol/types/flex-item";
|
|
4
|
+
import type { NestedItemBase } from "@matreshka/client-bff-protocol/types/nested-item-base";
|
|
5
5
|
import { Componentable, ComponentInstance, ComponentTreeNode, StandaloneComponent } from "../core";
|
|
6
6
|
import type { ActionConfig } from "../core/actions/action";
|
|
7
7
|
import { Component, ComponentInitConfig, ComponentProperties, ServerComponentAction } from "./component";
|
package/dist/components/board.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.itemList = exports.Board = exports.board = void 0;
|
|
4
|
-
const server_component_class_1 = require("@matreshka/
|
|
5
|
-
const board_set_center_message_1 = require("@matreshka/
|
|
6
|
-
const board_set_zoom_message_1 = require("@matreshka/
|
|
7
|
-
const board_zoom_in_message_1 = require("@matreshka/
|
|
8
|
-
const board_zoom_out_message_1 = require("@matreshka/
|
|
9
|
-
const flex_item_1 = require("@matreshka/
|
|
4
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
5
|
+
const board_set_center_message_1 = require("@matreshka/client-bff-protocol/messages/bff-to-client/components/board/board-set-center-message");
|
|
6
|
+
const board_set_zoom_message_1 = require("@matreshka/client-bff-protocol/messages/bff-to-client/components/board/board-set-zoom-message");
|
|
7
|
+
const board_zoom_in_message_1 = require("@matreshka/client-bff-protocol/messages/bff-to-client/components/board/board-zoom-in-message");
|
|
8
|
+
const board_zoom_out_message_1 = require("@matreshka/client-bff-protocol/messages/bff-to-client/components/board/board-zoom-out-message");
|
|
9
|
+
const flex_item_1 = require("@matreshka/client-bff-protocol/types/flex-item");
|
|
10
10
|
const component_local_actions_1 = require("../core/actions/component-local-actions");
|
|
11
11
|
const component_1 = require("./component");
|
|
12
12
|
const item_list_1 = require("./item-list");
|
package/dist/components/boot.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.bootServerComponents = void 0;
|
|
4
|
-
const index_1 = require("@matreshka/
|
|
4
|
+
const index_1 = require("@matreshka/client-bff-protocol/messages/bff-to-client/app/index");
|
|
5
5
|
const rxjs_1 = require("rxjs");
|
|
6
6
|
const core_1 = require("../core");
|
|
7
7
|
const bootServerComponents = (matreshka) => {
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { ServerComponentClass } from "@matreshka/
|
|
2
|
-
import { VideoFacingMode } from "@matreshka/
|
|
3
|
-
import { ErrorMessagePayload } from "@matreshka/
|
|
4
|
-
import type { CameraConfig } from "@matreshka/
|
|
1
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
2
|
+
import { VideoFacingMode } from "@matreshka/client-bff-protocol/enums/video-facing-mode";
|
|
3
|
+
import { ErrorMessagePayload } from "@matreshka/client-bff-protocol/messages/client-to-bff/error-message";
|
|
4
|
+
import type { CameraConfig } from "@matreshka/client-bff-protocol/types/camera-config";
|
|
5
5
|
import { Componentable, ComponentInstance, ComponentTreeNode, MixedWithCallbacksArray, StandaloneComponent } from "../core";
|
|
6
6
|
import type { ActionConfig } from "../core/actions/action";
|
|
7
7
|
import { VideoInputDevice } from "../platforms/platform";
|
|
8
8
|
import { Component, ComponentInitConfig, ComponentProperties, ServerComponentAction } from "./component";
|
|
9
|
-
export { VideoFacingMode } from "@matreshka/
|
|
9
|
+
export { VideoFacingMode } from "@matreshka/client-bff-protocol/enums/video-facing-mode";
|
|
10
10
|
export type CameraProperties = {
|
|
11
11
|
content: ComponentTreeNode[];
|
|
12
12
|
facingMode?: VideoFacingMode;
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Camera = exports.VideoFacingMode = void 0;
|
|
4
4
|
exports.camera = camera;
|
|
5
|
-
const server_component_class_1 = require("@matreshka/
|
|
6
|
-
const camera_switch_message_1 = require("@matreshka/
|
|
5
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
6
|
+
const camera_switch_message_1 = require("@matreshka/client-bff-protocol/messages/bff-to-client/components/camera/camera-switch-message");
|
|
7
7
|
const core_1 = require("../core");
|
|
8
8
|
const component_local_actions_1 = require("../core/actions/component-local-actions");
|
|
9
9
|
const component_1 = require("./component");
|
|
10
|
-
var video_facing_mode_1 = require("@matreshka/
|
|
10
|
+
var video_facing_mode_1 = require("@matreshka/client-bff-protocol/enums/video-facing-mode");
|
|
11
11
|
Object.defineProperty(exports, "VideoFacingMode", { enumerable: true, get: function () { return video_facing_mode_1.VideoFacingMode; } });
|
|
12
12
|
function camera(arg0, arg1) {
|
|
13
13
|
if (arg1 !== undefined) {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { ChartType } from "@matreshka/
|
|
2
|
-
import { ServerComponentClass } from "@matreshka/
|
|
1
|
+
import { ChartType } from "@matreshka/client-bff-protocol/enums/chart-type";
|
|
2
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
3
3
|
import type { Componentable } from "../../core/types/componentable";
|
|
4
4
|
import { StandaloneComponent } from "../../core/types/standalone-component";
|
|
5
5
|
import { Component, ComponentInitConfig, ComponentProperties } from "../component";
|
|
6
|
-
export { ChartType } from "@matreshka/
|
|
6
|
+
export { ChartType } from "@matreshka/client-bff-protocol/enums/chart-type";
|
|
7
7
|
/**
|
|
8
8
|
* Описание набора данных для графика.
|
|
9
9
|
* @property label Название набора данных.
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Chart = exports.ChartType = void 0;
|
|
4
|
-
const server_component_class_1 = require("@matreshka/
|
|
4
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
5
5
|
const component_1 = require("../component");
|
|
6
|
-
var chart_type_1 = require("@matreshka/
|
|
6
|
+
var chart_type_1 = require("@matreshka/client-bff-protocol/enums/chart-type");
|
|
7
7
|
Object.defineProperty(exports, "ChartType", { enumerable: true, get: function () { return chart_type_1.ChartType; } });
|
|
8
8
|
/**
|
|
9
9
|
* Абстрактный класс графика.
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { ColorRole } from "@matreshka/
|
|
2
|
-
import { ServerComponentClass } from "@matreshka/
|
|
3
|
-
import { TextAlign } from "@matreshka/
|
|
4
|
-
import { TextDecoration } from "@matreshka/
|
|
5
|
-
import { ComponentCommandMessage } from "@matreshka/
|
|
6
|
-
import { ColorToken } from "@matreshka/
|
|
7
|
-
import type { Overlay as ClientOverlayShape } from "@matreshka/
|
|
8
|
-
import type { FontStackToken } from "@matreshka/
|
|
9
|
-
import type { GridItem } from "@matreshka/
|
|
10
|
-
import type { ServerComponentConfig } from "@matreshka/
|
|
1
|
+
import { ColorRole } from "@matreshka/client-bff-protocol/enums/color-role";
|
|
2
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
3
|
+
import { TextAlign } from "@matreshka/client-bff-protocol/enums/text-align";
|
|
4
|
+
import { TextDecoration } from "@matreshka/client-bff-protocol/enums/text-decoration";
|
|
5
|
+
import { ComponentCommandMessage } from "@matreshka/client-bff-protocol/messages/bff-to-client/component-command-message";
|
|
6
|
+
import { ColorToken } from "@matreshka/client-bff-protocol/types/color-token";
|
|
7
|
+
import type { Overlay as ClientOverlayShape } from "@matreshka/client-bff-protocol/types/container-overlay";
|
|
8
|
+
import type { FontStackToken } from "@matreshka/client-bff-protocol/types/fonts";
|
|
9
|
+
import type { GridItem } from "@matreshka/client-bff-protocol/types/grid-item";
|
|
10
|
+
import type { ServerComponentConfig } from "@matreshka/client-bff-protocol/types/server-component-config";
|
|
11
11
|
import { Observable, Subscription } from "rxjs";
|
|
12
12
|
import { Client, Componentable, ComponentInstance } from "../core";
|
|
13
13
|
import { LocalAction } from "../core/actions/local-action";
|
|
@@ -34,8 +34,8 @@ var __importStar = (this && this.__importStar) || (function () {
|
|
|
34
34
|
})();
|
|
35
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
36
|
exports.Component = void 0;
|
|
37
|
+
const component_interaction_message_1 = require("@matreshka/client-bff-protocol/messages/client-to-bff/components/component-interaction-message");
|
|
37
38
|
const shared_1 = require("@matreshka/shared");
|
|
38
|
-
const component_interaction_message_1 = require("@matreshka/shared/messages/client-to-bff/components/component-interaction-message");
|
|
39
39
|
const crypto = __importStar(require("node:crypto"));
|
|
40
40
|
const rxjs_1 = require("rxjs");
|
|
41
41
|
const core_1 = require("../core");
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ServerComponentClass } from "@matreshka/
|
|
2
|
-
import type { ContainerConfig } from "@matreshka/
|
|
1
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
2
|
+
import type { ContainerConfig } from "@matreshka/client-bff-protocol/types/container-config";
|
|
3
3
|
import { Componentable, ComponentTreeNode, MixedWithCallbacksArray, StandaloneComponent } from "../core";
|
|
4
4
|
import { Component, ComponentInitConfig, ComponentProperties } from "./component";
|
|
5
5
|
export type ContainerProperties = {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Container = void 0;
|
|
4
4
|
exports.container = container;
|
|
5
|
-
const server_component_class_1 = require("@matreshka/
|
|
5
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
6
6
|
const core_1 = require("../core");
|
|
7
7
|
const component_1 = require("./component");
|
|
8
8
|
function container(arg0, arg1) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ServerComponentClass } from "@matreshka/
|
|
2
|
-
import { OverlayAnchor } from "@matreshka/
|
|
3
|
-
import type { DialogBackdropConfig } from "@matreshka/
|
|
4
|
-
import type { DialogConfig } from "@matreshka/
|
|
1
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
2
|
+
import { OverlayAnchor } from "@matreshka/client-bff-protocol/types/container-overlay";
|
|
3
|
+
import type { DialogBackdropConfig } from "@matreshka/client-bff-protocol/types/dialog-backdrop-config";
|
|
4
|
+
import type { DialogConfig } from "@matreshka/client-bff-protocol/types/dialog-config";
|
|
5
5
|
import { Componentable, ComponentInstance, ComponentTreeNode, MixedWithCallbacksArray } from "../core";
|
|
6
6
|
import type { ActionConfig } from "../core/actions/action";
|
|
7
7
|
import type { AnimateComponent } from "../core/actions/animate-component";
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Dialog = void 0;
|
|
4
4
|
exports.dialog = dialog;
|
|
5
|
-
const server_component_class_1 = require("@matreshka/
|
|
6
|
-
const dialog_close_message_1 = require("@matreshka/
|
|
5
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
6
|
+
const dialog_close_message_1 = require("@matreshka/client-bff-protocol/messages/bff-to-client/components/dialog/dialog-close-message");
|
|
7
7
|
const core_1 = require("../core");
|
|
8
8
|
const close_entry_1 = require("../core/actions/close-entry");
|
|
9
9
|
const entry_component_1 = require("./entry-component");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { EntryServerComponentConfig } from "@matreshka/
|
|
1
|
+
import type { EntryServerComponentConfig } from "@matreshka/client-bff-protocol/types/entry-server-component-config";
|
|
2
2
|
import type { Client } from "../core/client";
|
|
3
3
|
import type { ComponentInstance } from "../core/types/component-instance";
|
|
4
4
|
import type { Componentable } from "../core/types/componentable";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.EntryComponent = void 0;
|
|
4
|
-
const web_mcp_tool_call_message_1 = require("@matreshka/
|
|
4
|
+
const web_mcp_tool_call_message_1 = require("@matreshka/client-bff-protocol/messages/client-to-bff/webmcp/web-mcp-tool-call-message");
|
|
5
5
|
const rxjs_1 = require("rxjs");
|
|
6
6
|
const client_context_1 = require("../core/client-context");
|
|
7
7
|
const entry_context_1 = require("../core/entry-context");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { PasswordInputKind } from "@matreshka/
|
|
1
|
+
export { PasswordInputKind } from "@matreshka/client-bff-protocol/enums/password-input-kind";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.PasswordInputKind = void 0;
|
|
4
|
-
var password_input_kind_1 = require("@matreshka/
|
|
4
|
+
var password_input_kind_1 = require("@matreshka/client-bff-protocol/enums/password-input-kind");
|
|
5
5
|
Object.defineProperty(exports, "PasswordInputKind", { enumerable: true, get: function () { return password_input_kind_1.PasswordInputKind; } });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { PopoverPositionArea } from "@matreshka/
|
|
1
|
+
export { PopoverPositionArea } from "@matreshka/client-bff-protocol/enums/popover-position-area";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.PopoverPositionArea = void 0;
|
|
4
|
-
var popover_position_area_1 = require("@matreshka/
|
|
4
|
+
var popover_position_area_1 = require("@matreshka/client-bff-protocol/enums/popover-position-area");
|
|
5
5
|
Object.defineProperty(exports, "PopoverPositionArea", { enumerable: true, get: function () { return popover_position_area_1.PopoverPositionArea; } });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { ScrollToPosition } from "@matreshka/
|
|
1
|
+
export { ScrollToPosition } from "@matreshka/client-bff-protocol/enums/scroll-to-position";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ScrollToPosition = void 0;
|
|
4
|
-
var scroll_to_position_1 = require("@matreshka/
|
|
4
|
+
var scroll_to_position_1 = require("@matreshka/client-bff-protocol/enums/scroll-to-position");
|
|
5
5
|
Object.defineProperty(exports, "ScrollToPosition", { enumerable: true, get: function () { return scroll_to_position_1.ScrollToPosition; } });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { TextInputKind } from "@matreshka/
|
|
1
|
+
export { TextInputKind } from "@matreshka/client-bff-protocol/enums/text-input-kind";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TextInputKind = void 0;
|
|
4
|
-
var text_input_kind_1 = require("@matreshka/
|
|
4
|
+
var text_input_kind_1 = require("@matreshka/client-bff-protocol/enums/text-input-kind");
|
|
5
5
|
Object.defineProperty(exports, "TextInputKind", { enumerable: true, get: function () { return text_input_kind_1.TextInputKind; } });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { TextareaResize } from "@matreshka/
|
|
1
|
+
export { TextareaResize } from "@matreshka/client-bff-protocol/enums/textarea-resize";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TextareaResize = void 0;
|
|
4
|
-
var textarea_resize_1 = require("@matreshka/
|
|
4
|
+
var textarea_resize_1 = require("@matreshka/client-bff-protocol/enums/textarea-resize");
|
|
5
5
|
Object.defineProperty(exports, "TextareaResize", { enumerable: true, get: function () { return textarea_resize_1.TextareaResize; } });
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ServerComponentClass } from "@matreshka/
|
|
2
|
-
import type { FileUploadAreaConfig } from "@matreshka/
|
|
1
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
2
|
+
import type { FileUploadAreaConfig } from "@matreshka/client-bff-protocol/types/file-upload-area-config";
|
|
3
3
|
import { Componentable, ComponentTreeNode, MixedWithCallbacksArray, StandaloneComponent } from "../core";
|
|
4
4
|
import { Component, ComponentInitConfig, ComponentProperties } from "./component";
|
|
5
5
|
/**
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.FileUploadArea = void 0;
|
|
4
4
|
exports.fileUploadArea = fileUploadArea;
|
|
5
|
-
const server_component_class_1 = require("@matreshka/
|
|
6
|
-
const
|
|
5
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
6
|
+
const zod_1 = require("zod");
|
|
7
7
|
const core_1 = require("../core");
|
|
8
8
|
const component_1 = require("./component");
|
|
9
9
|
function fileUploadArea(arg0, arg1) {
|
|
@@ -23,13 +23,13 @@ class FileUploadArea extends component_1.Component {
|
|
|
23
23
|
super(config);
|
|
24
24
|
this.uploadMap = new Map();
|
|
25
25
|
this.onInteraction("start", ({ payload }) => {
|
|
26
|
-
const schema =
|
|
27
|
-
id:
|
|
28
|
-
type:
|
|
29
|
-
size:
|
|
30
|
-
name:
|
|
31
|
-
lastModified:
|
|
32
|
-
url:
|
|
26
|
+
const schema = zod_1.z.strictObject({
|
|
27
|
+
id: zod_1.z.string(),
|
|
28
|
+
type: zod_1.z.string(),
|
|
29
|
+
size: zod_1.z.number(),
|
|
30
|
+
name: zod_1.z.string(),
|
|
31
|
+
lastModified: zod_1.z.number(),
|
|
32
|
+
url: zod_1.z.string().refine((val) => val.startsWith("blob:"), {
|
|
33
33
|
message: "url must be a blob",
|
|
34
34
|
}),
|
|
35
35
|
});
|
|
@@ -38,10 +38,10 @@ class FileUploadArea extends component_1.Component {
|
|
|
38
38
|
this.config.onStart?.(safePayload);
|
|
39
39
|
});
|
|
40
40
|
this.onInteraction("progress", ({ payload }) => {
|
|
41
|
-
const schema =
|
|
41
|
+
const schema = zod_1.z
|
|
42
42
|
.strictObject({
|
|
43
|
-
id:
|
|
44
|
-
progress:
|
|
43
|
+
id: zod_1.z.string(),
|
|
44
|
+
progress: zod_1.z.number().min(0).max(100),
|
|
45
45
|
})
|
|
46
46
|
.refine((data) => this.uploadMap.has(data.id), {
|
|
47
47
|
message: "Unknown upload id",
|
|
@@ -54,10 +54,10 @@ class FileUploadArea extends component_1.Component {
|
|
|
54
54
|
});
|
|
55
55
|
});
|
|
56
56
|
this.onInteraction("complete", ({ payload }) => {
|
|
57
|
-
const schema =
|
|
57
|
+
const schema = zod_1.z
|
|
58
58
|
.strictObject({
|
|
59
|
-
id:
|
|
60
|
-
response:
|
|
59
|
+
id: zod_1.z.string(),
|
|
60
|
+
response: zod_1.z.unknown(),
|
|
61
61
|
})
|
|
62
62
|
.refine((data) => this.uploadMap.has(data.id), {
|
|
63
63
|
message: "Unknown upload id",
|
|
@@ -70,11 +70,11 @@ class FileUploadArea extends component_1.Component {
|
|
|
70
70
|
});
|
|
71
71
|
});
|
|
72
72
|
this.onInteraction("error", ({ payload }) => {
|
|
73
|
-
const schema =
|
|
73
|
+
const schema = zod_1.z
|
|
74
74
|
.strictObject({
|
|
75
|
-
id:
|
|
76
|
-
response:
|
|
77
|
-
code:
|
|
75
|
+
id: zod_1.z.string(),
|
|
76
|
+
response: zod_1.z.unknown(),
|
|
77
|
+
code: zod_1.z.number(), // Не StatusCode, потому что может быть 0, который не содержится в словаре
|
|
78
78
|
})
|
|
79
79
|
.refine((data) => this.uploadMap.has(data.id), {
|
|
80
80
|
message: "Unknown upload id",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ServerComponentClass } from "@matreshka/
|
|
2
|
-
import type { ForEachConfig } from "@matreshka/
|
|
1
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
2
|
+
import type { ForEachConfig } from "@matreshka/client-bff-protocol/types/for-each-config";
|
|
3
3
|
import { Paths, PathValue } from "ts-essentials";
|
|
4
4
|
import { ComponentInstance, ComponentTreeNode, Context, ContextRef, ContextRefValue, JsonObject, StandaloneComponent } from "../core";
|
|
5
5
|
import { Component, ComponentInitConfig, ComponentProperties } from "./component";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ForEach = exports.forEach = void 0;
|
|
4
|
-
const server_component_class_1 = require("@matreshka/
|
|
5
|
-
const for_each_sync_components_message_1 = require("@matreshka/
|
|
4
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
5
|
+
const for_each_sync_components_message_1 = require("@matreshka/client-bff-protocol/messages/bff-to-client/components/for-each/for-each-sync-components-message");
|
|
6
6
|
const rxjs_1 = require("rxjs");
|
|
7
|
-
const
|
|
7
|
+
const zod_1 = require("zod");
|
|
8
8
|
const core_1 = require("../core");
|
|
9
9
|
const serialize_component_tree_1 = require("../core/utils/serialize-component-tree");
|
|
10
10
|
const track_created_instances_1 = require("../core/utils/track-created-instances");
|
|
@@ -47,7 +47,7 @@ class ForEachContext extends core_1.Context {
|
|
|
47
47
|
super({
|
|
48
48
|
data: async () => ({}),
|
|
49
49
|
preload: preload,
|
|
50
|
-
schema:
|
|
50
|
+
schema: zod_1.z.strictObject({}), // Запрет изменения из внешних источников
|
|
51
51
|
});
|
|
52
52
|
}
|
|
53
53
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ServerComponentClass } from "@matreshka/
|
|
2
|
-
import type { FormConfig } from "@matreshka/
|
|
1
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
2
|
+
import type { FormConfig } from "@matreshka/client-bff-protocol/types/form-config";
|
|
3
3
|
import { Componentable, ComponentTreeNode, MixedWithCallbacksArray, StandaloneComponent } from "../core";
|
|
4
4
|
import { Component, ComponentInitConfig, ComponentProperties, ServerComponentAction } from "./component";
|
|
5
5
|
export type FormProperties = {
|
package/dist/components/form.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Form = void 0;
|
|
4
4
|
exports.form = form;
|
|
5
|
-
const server_component_class_1 = require("@matreshka/
|
|
5
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
6
6
|
const core_1 = require("../core");
|
|
7
7
|
const component_1 = require("./component");
|
|
8
8
|
function form(arg0, arg1) {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { GridColumnSize } from "@matreshka/
|
|
2
|
-
import { GridTemplateColumns } from "@matreshka/
|
|
3
|
-
import { ServerComponentClass } from "@matreshka/
|
|
4
|
-
import { type FlexItemSpec } from "@matreshka/
|
|
5
|
-
import type { GridConfig } from "@matreshka/
|
|
6
|
-
import type { GridGap } from "@matreshka/
|
|
1
|
+
import { GridColumnSize } from "@matreshka/client-bff-protocol/enums/grid-column-size";
|
|
2
|
+
import { GridTemplateColumns } from "@matreshka/client-bff-protocol/enums/grid-template-columns";
|
|
3
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
4
|
+
import { type FlexItemSpec } from "@matreshka/client-bff-protocol/types/flex-item";
|
|
5
|
+
import type { GridConfig } from "@matreshka/client-bff-protocol/types/grid-config";
|
|
6
|
+
import type { GridGap } from "@matreshka/client-bff-protocol/types/grid-gap";
|
|
7
7
|
import { Componentable, ComponentTreeNode, StandaloneComponent } from "../core";
|
|
8
8
|
import { Component, ComponentInitConfig, ComponentProperties } from "./component";
|
|
9
9
|
import { ComponentSequence } from "./types/component-sequence";
|
package/dist/components/grid.js
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Grid = void 0;
|
|
4
4
|
exports.grid = grid;
|
|
5
|
-
const server_component_class_1 = require("@matreshka/
|
|
6
|
-
const flex_item_1 = require("@matreshka/
|
|
5
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
6
|
+
const flex_item_1 = require("@matreshka/client-bff-protocol/types/flex-item");
|
|
7
7
|
const core_1 = require("../core");
|
|
8
8
|
const component_1 = require("./component");
|
|
9
9
|
function grid(arg0, arg1) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export * from "./actions/server-action";
|
|
2
|
-
export { OverlayAnchor } from "@matreshka/
|
|
2
|
+
export { OverlayAnchor } from "@matreshka/client-bff-protocol/types/container-overlay";
|
|
3
3
|
export * from "./aliases/button";
|
|
4
4
|
export * from "./aliases/column";
|
|
5
5
|
export * from "./aliases/row";
|
package/dist/components/index.js
CHANGED
|
@@ -16,7 +16,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
exports.webMcpTool = exports.WebMcpToolAnnotation = exports.WebMcpTool = exports.isStandaloneComponentLike = exports.scrollDistanceToEnd = exports.needsMore = exports.OverlayAnchor = void 0;
|
|
18
18
|
__exportStar(require("./actions/server-action"), exports);
|
|
19
|
-
var container_overlay_1 = require("@matreshka/
|
|
19
|
+
var container_overlay_1 = require("@matreshka/client-bff-protocol/types/container-overlay");
|
|
20
20
|
Object.defineProperty(exports, "OverlayAnchor", { enumerable: true, get: function () { return container_overlay_1.OverlayAnchor; } });
|
|
21
21
|
__exportStar(require("./aliases/button"), exports);
|
|
22
22
|
__exportStar(require("./aliases/column"), exports);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ServerComponentClass } from "@matreshka/
|
|
1
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
2
2
|
import { Componentable } from "../../core";
|
|
3
3
|
import { InputComponent, InputContextRef, InputInitConfig, InputProperties } from "./input-component";
|
|
4
4
|
export type NumberInputProperties = {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.NumberInput = void 0;
|
|
4
4
|
exports.numberInput = numberInput;
|
|
5
|
-
const server_component_class_1 = require("@matreshka/
|
|
5
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
6
6
|
const core_1 = require("../../core");
|
|
7
7
|
const input_component_1 = require("./input-component");
|
|
8
8
|
function numberInput(arg0, arg1) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { PasswordInputKind } from "@matreshka/
|
|
2
|
-
import { ServerComponentClass } from "@matreshka/
|
|
1
|
+
import { PasswordInputKind } from "@matreshka/client-bff-protocol/enums/password-input-kind";
|
|
2
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
3
3
|
import { Componentable } from "../../core";
|
|
4
4
|
import { InputComponent, InputInitConfig, InputProperties, StringInputContextRef } from "./input-component";
|
|
5
5
|
export type PasswordInputProperties = {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.PasswordInput = void 0;
|
|
4
4
|
exports.passwordInput = passwordInput;
|
|
5
|
-
const server_component_class_1 = require("@matreshka/
|
|
5
|
+
const server_component_class_1 = require("@matreshka/client-bff-protocol/enums/server-component-class");
|
|
6
6
|
const core_1 = require("../../core");
|
|
7
7
|
const input_component_1 = require("./input-component");
|
|
8
8
|
function passwordInput(arg0, arg1) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ServerComponentClass } from "@matreshka/
|
|
1
|
+
import { ServerComponentClass } from "@matreshka/client-bff-protocol/enums/server-component-class";
|
|
2
2
|
import { Componentable, ComponentInstance } from "../../core";
|
|
3
3
|
import type { ActionConfig } from "../../core/actions/action";
|
|
4
4
|
import { ServerComponentAction } from "../component";
|