@yongdall/web 0.4.5 → 0.4.6
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/index.d.mts +46 -16
- package/index.mjs +14 -14
- package/index.mjs.map +1 -1
- package/package.json +1 -1
package/index.d.mts
CHANGED
|
@@ -1713,6 +1713,29 @@ declare namespace DataSource {
|
|
|
1713
1713
|
};
|
|
1714
1714
|
}
|
|
1715
1715
|
//#endregion
|
|
1716
|
+
//#region packages/web/request.d.mts
|
|
1717
|
+
/**
|
|
1718
|
+
* @callback ErrorAlerter
|
|
1719
|
+
* @param {*} error
|
|
1720
|
+
* @returns {PromiseLike<void> | void}
|
|
1721
|
+
*/
|
|
1722
|
+
/**
|
|
1723
|
+
* @param {*} error
|
|
1724
|
+
* @returns {PromiseLike<void> | void}
|
|
1725
|
+
*/
|
|
1726
|
+
declare function ErrorAlerter(error: any): PromiseLike<void> | void;
|
|
1727
|
+
type ErrorAlerter = (error: any) => PromiseLike<void> | void;
|
|
1728
|
+
declare class ARequest extends DotRequest$1 {
|
|
1729
|
+
/**
|
|
1730
|
+
*
|
|
1731
|
+
* @param {string} method
|
|
1732
|
+
* @param {string} [path]
|
|
1733
|
+
* @returns
|
|
1734
|
+
*/
|
|
1735
|
+
method(method: string, path?: string): this;
|
|
1736
|
+
}
|
|
1737
|
+
declare const request: ARequest;
|
|
1738
|
+
//#endregion
|
|
1716
1739
|
//#region packages/web/typesDefine.d.mts
|
|
1717
1740
|
interface CurrentPage {
|
|
1718
1741
|
title: string;
|
|
@@ -1917,6 +1940,7 @@ interface Theme {
|
|
|
1917
1940
|
updatePath: (path: string, search: string, hash: string, page: (PageIdent & {
|
|
1918
1941
|
path: string;
|
|
1919
1942
|
}) | null) => void;
|
|
1943
|
+
alertError: ErrorAlerter;
|
|
1920
1944
|
/** 自动加载的样式文件 */
|
|
1921
1945
|
styleFiles: string[];
|
|
1922
1946
|
/** 添加到 <body> 上的类名 */
|
|
@@ -2504,17 +2528,35 @@ declare namespace pathRoots {
|
|
|
2504
2528
|
declare function createModelDefault(model: ModelScriptConfiguration | ModelConfiguration, params: Record<string, any> | [key: string, value: any][], defaultValue?: Record<string, any>): any;
|
|
2505
2529
|
//#endregion
|
|
2506
2530
|
//#region packages/web/model/createDocumentInModal.d.mts
|
|
2531
|
+
/**
|
|
2532
|
+
*
|
|
2533
|
+
* @param {Modal} modal
|
|
2534
|
+
* @param {ModelScriptConfiguration} model
|
|
2535
|
+
* @param {ReturnType<typeof modelService> | string} currentModel
|
|
2536
|
+
* @param {FormLayout?} [layout]
|
|
2537
|
+
* @param {Record<string, any> | [key: string, value: any][] | null} [newParams]
|
|
2538
|
+
*/
|
|
2539
|
+
declare function createDocumentInModal(modal: Modal, model: ModelScriptConfiguration, currentModel: ReturnType<typeof modelService> | string, layout?: FormLayout | null, newParams?: Record<string, any> | [key: string, value: any][] | null): Promise<any>;
|
|
2540
|
+
//#endregion
|
|
2541
|
+
//#region packages/web/model/showDocumentInModal.d.mts
|
|
2507
2542
|
/** @import { Modal } from '../dom/index.mjs' */
|
|
2508
|
-
/** @import { ModelScriptConfiguration, modelService } from '../services/model.mjs' */
|
|
2509
2543
|
/**
|
|
2510
2544
|
*
|
|
2511
2545
|
* @param {Modal} modal
|
|
2512
2546
|
* @param {ModelScriptConfiguration} model
|
|
2513
2547
|
* @param {ReturnType<typeof modelService>} currentModel
|
|
2548
|
+
* @param {string} id
|
|
2514
2549
|
* @param {FormLayout?} [layout]
|
|
2515
|
-
* @param {
|
|
2550
|
+
* @param {object} [options]
|
|
2551
|
+
* @param {string} [options.href]
|
|
2552
|
+
* @param {boolean} [options.editable]
|
|
2553
|
+
* @param {boolean} [options.destroyable]
|
|
2516
2554
|
*/
|
|
2517
|
-
declare function
|
|
2555
|
+
declare function showDocumentInModal(modal: Modal, model: ModelScriptConfiguration, currentModel: ReturnType<typeof modelService>, id: string, layout?: FormLayout | null, options?: {
|
|
2556
|
+
href?: string | undefined;
|
|
2557
|
+
editable?: boolean | undefined;
|
|
2558
|
+
destroyable?: boolean | undefined;
|
|
2559
|
+
}): Promise<void>;
|
|
2518
2560
|
//#endregion
|
|
2519
2561
|
//#region packages/web/model/index.d.mts
|
|
2520
2562
|
/**
|
|
@@ -2697,18 +2739,6 @@ declare function stringify(a: PageIdent): string;
|
|
|
2697
2739
|
*/
|
|
2698
2740
|
declare function stringifyPaths(a: PageIdent): Iterable<string>;
|
|
2699
2741
|
//#endregion
|
|
2700
|
-
//#region packages/web/request.d.mts
|
|
2701
|
-
declare class ARequest extends DotRequest$1 {
|
|
2702
|
-
/**
|
|
2703
|
-
*
|
|
2704
|
-
* @param {string} method
|
|
2705
|
-
* @param {string} [path]
|
|
2706
|
-
* @returns
|
|
2707
|
-
*/
|
|
2708
|
-
method(method: string, path?: string): this;
|
|
2709
|
-
}
|
|
2710
|
-
declare const request: ARequest;
|
|
2711
|
-
//#endregion
|
|
2712
2742
|
//#region packages/web/ResponseError.d.mts
|
|
2713
2743
|
declare class ResponseError extends Error {
|
|
2714
2744
|
/**
|
|
@@ -2916,4 +2946,4 @@ declare function updateHooks(hooks: Record<string, Hook.Define<Hooks>>): void;
|
|
|
2916
2946
|
/** @type {Hook<Hooks>} */
|
|
2917
2947
|
declare const allHooks: Hook<Hooks>;
|
|
2918
2948
|
//#endregion
|
|
2919
|
-
export { ArrayStore, Authenticator, BindObjectStore, code128_d_exports as Code128, Command, ConfiguratorComponent, ConfiguratorContext, type ContinuationDefine, CurrentPage, type DataSource, DotRequest, FieldComponent, FieldComponentEvent, FieldComponents, FieldContext, FieldDefine, FieldFilter, FieldFilterComponent, FieldFilterContext, FieldFilterFns, FieldFilterOptions, FieldFilterStyle, type FieldScript, type FieldScriptConfiguration, FieldShowHandle, FieldStyle, FilterFns, FormFieldHook, FromRenderer, GeneralContext, type HomeContext, Hooks, IconDefine, Ident_d_exports as Ident, List, type Match, Menu, Modal, ModalFooter, ModalHeader, type ModelConfiguration, ModelIndicator, type ModelScript, type ModelScriptConfiguration, ObjectStore, Page, type PageConfiguration, type PageContext, type PageError, PageFooter, PageFrame, type PageHandle, PageHeader, PageIdent, type PageManager, type PageRenderer, PageSection, PageSectionParam, PageSider, Pagination, type Print, ResponseError, type Schema, Signal$1 as Signal, State, Store, type StoreLayout, SubmodelsLayoutEvent, Theme, User, UserHook, VerifyContext, VerifyError, type WorkspaceDefine, addManager, allHooks, application, buildDataSource, buildPlugin, createComputed, createDeeply, createDialog, createDocumentInModal, createFilters, createFrame, createIcon, createModal, createModelDefault, createQuickFilters, createShowField, createState, createStore, createStoreField, createTick, effect, enumerationsService, execScript, filterPermission, flatPermission, formLayoutsService, getAllFilterFns, getAuthorizations, getField, getFieldFilter, getFieldFilterOperators, getFilterFns, getPages, getPermissionFields, getPrimaryFields, hasField, hasFieldFilter, importStyle, importWidget, isMac, isPluginId, loadMenu, modelService, neverAbortedSignal, pathRoots, _default as permissionsService, plugins, _default$1 as renderForm, renderStore, _default$2 as renderStoreForm, request, root$1 as root, selectFile, setIcon, showFilterDialog, start, testPermission, testPermissionConstraints, testPermissions, toFileLink, toFileURL, toId, toPermissionFilter, toSchema, toUrl, updateHooks, waitAbortSignal, watch };
|
|
2949
|
+
export { ArrayStore, Authenticator, BindObjectStore, code128_d_exports as Code128, Command, ConfiguratorComponent, ConfiguratorContext, type ContinuationDefine, CurrentPage, type DataSource, DotRequest, ErrorAlerter, FieldComponent, FieldComponentEvent, FieldComponents, FieldContext, FieldDefine, FieldFilter, FieldFilterComponent, FieldFilterContext, FieldFilterFns, FieldFilterOptions, FieldFilterStyle, type FieldScript, type FieldScriptConfiguration, FieldShowHandle, FieldStyle, FilterFns, FormFieldHook, FromRenderer, GeneralContext, type HomeContext, Hooks, IconDefine, Ident_d_exports as Ident, List, type Match, Menu, Modal, ModalFooter, ModalHeader, type ModelConfiguration, ModelIndicator, type ModelScript, type ModelScriptConfiguration, ObjectStore, Page, type PageConfiguration, type PageContext, type PageError, PageFooter, PageFrame, type PageHandle, PageHeader, PageIdent, type PageManager, type PageRenderer, PageSection, PageSectionParam, PageSider, Pagination, type Print, ResponseError, type Schema, Signal$1 as Signal, State, Store, type StoreLayout, SubmodelsLayoutEvent, Theme, User, UserHook, VerifyContext, VerifyError, type WorkspaceDefine, addManager, allHooks, application, buildDataSource, buildPlugin, createComputed, createDeeply, createDialog, createDocumentInModal, createFilters, createFrame, createIcon, createModal, createModelDefault, createQuickFilters, createShowField, createState, createStore, createStoreField, createTick, effect, enumerationsService, execScript, filterPermission, flatPermission, formLayoutsService, getAllFilterFns, getAuthorizations, getField, getFieldFilter, getFieldFilterOperators, getFilterFns, getPages, getPermissionFields, getPrimaryFields, hasField, hasFieldFilter, importStyle, importWidget, isMac, isPluginId, loadMenu, modelService, neverAbortedSignal, pathRoots, _default as permissionsService, plugins, _default$1 as renderForm, renderStore, _default$2 as renderStoreForm, request, root$1 as root, selectFile, setIcon, showDocumentInModal, showFilterDialog, start, testPermission, testPermissionConstraints, testPermissions, toFileLink, toFileURL, toId, toPermissionFilter, toSchema, toUrl, updateHooks, waitAbortSignal, watch };
|