@dxtmisha/functional 1.13.2 → 1.13.4

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/CHANGELOG.md CHANGED
@@ -2,6 +2,21 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
+ ## [1.13.4] - 2026-06-17
6
+
7
+ ### Added
8
+ - **GeoRef**: Added static reactive `setValueDefault` method to configure the default country/language code.
9
+ - **dxtFunctionalPlugin**: Extended `location` configuration option to accept `string | (() => string)` callbacks, registering the default fallback location dynamically during Vue application initialization.
10
+
11
+ ## [1.13.3] - 2026-06-16
12
+
13
+ ### Added
14
+ - **GeoRef**: Added static reactive `setValueDefault` method to configure the default country/language code.
15
+ - **dxtFunctionalPlugin**: Added `location?: string` plugin configuration parameter to set the default fallback location dynamically during Vue application initialization.
16
+
17
+ ### Changed / Improved
18
+ - **Tests**: Configured test suites (`GeoRef.test.ts` and `dxtFunctionalPlugin.test.ts`) to cover fallback value detection and default settings.
19
+
5
20
  ## [1.13.2] - 2026-06-05
6
21
 
7
22
  ### Changed / Improved
@@ -1,10 +1,18 @@
1
- Core Purpose: This library is a comprehensive Vue 3 framework for reactive application architecture. It provides high-level abstractions for API orchestration (fetching, mutation, SSR, schema validation), state management (singletons, reactive storage, session/cookie handling), component design (base classes for rendering and lifecycle management), and localization/internationalization (geo-data, formatting, date management).
1
+ This library is a collection of Vue 3-based utility classes and composables designed for building complex, reactive, and SSR-ready interfaces. It provides a standardized framework for API management, component state, geographic/localization data, and dynamic rendering.
2
2
 
3
- Usage Scenarios: Study this API when building complex, data-intensive Vue 3 applications requiring:
4
- 1. Centralized, reactive API management (GET/POST/PUT/DELETE) with built-in SSR support, caching, and automatic response contract validation.
5
- 2. Unified component architecture using base design classes for consistent styling, rendering, and lifecycle event management.
6
- 3. Complex list handling, client-side searching, and advanced data formatting (Intl, currency, dates).
7
- 4. Cross-tab communication or persistent reactive state storage (localStorage, sessionStorage, cookies).
8
- 5. Global service configuration (meta tags, translation, icons, API settings) via Vue plugins.
3
+ 1. Core Purpose:
4
+ An infrastructure-level toolkit for Vue 3 that abstracts asynchronous data fetching, state management, and UI rendering logic. It provides structured classes and composables to handle API lifecycle (GET/POST/PUT/DELETE), reactive data transformations, internationalization (Intl), and component orchestration.
9
5
 
10
- Integration Context: The library acts as a core infrastructure layer. It is built on top of Vue 3's Composition API and `vue-router`. It relies heavily on `@dxtmisha/functional-basic` for underlying logic. It should be treated as the primary service and utility layer that replaces manual store management (like Pinia) and repetitive API/lifecycle boilerplate by providing standardized patterns (e.g., `executeUse` for singletons) for shared state and service orchestration.
6
+ 2. Usage Scenarios:
7
+ - API Orchestration: When building complex forms, data tables, or dashboards requiring integrated state, validation (via @effect/schema compatibility), and SSR support. Use `useApiManagementRef` for unified CRUD handling or `useApiRef` for individual requests.
8
+ - Reactive Data Management: When you need synchronized data across browser tabs (`useBroadcastValueRef`) or persistence across reloads (`useStorageRef`, `useCookieRef`).
9
+ - Localization & Formatting: When the application needs to dynamically handle geographic data, currency formatting, file sizes, or date manipulation via `GeoIntlRef` and `useGeoIntlRef`.
10
+ - Component Design System: When building modular UI components that require consistent prop-to-style/class mapping (`DesignConstructorAbstract`, `DesignComponents`).
11
+ - Lifecycle & DOM Utilities: When implementing lazy loading (`useLazyRef`) or global state management using `executeUse` for singletons.
12
+
13
+ 3. Integration Context:
14
+ - Vue 3 Core: Heavily leverages `Ref`, `ComputedRef`, and `provide/inject`.
15
+ - Data Fetching: Acts as a high-level wrapper over an underlying `functional-basic` library.
16
+ - Routing: Integrates with `vue-router` via `RouterItemRef` and `useRouterList`.
17
+ - SSR: Provides specific `Async` variants (e.g., `useApiAsyncRef`) for server-side pre-fetching.
18
+ - Schema Validation: Designed to work with `@effect/schema` for robust API contract validation.
package/ai-types.txt CHANGED
@@ -16,20 +16,27 @@ The following is the content of "exports" from package.json:
16
16
 
17
17
  // File: src/classes/design/DesignAbstract.d.ts
18
18
  export declare abstract class DesignAbstract<T extends Record<string, any>, C extends Record<string, any>> {
19
+ protected readonly props: T;
20
+ protected readonly callback?: ((event: C) => void) | undefined;
21
+ protected readonly event: C;
22
+ protected readonly changed: DesignChanged<T>;
19
23
  constructor(props: T, callback?: ((event: C) => void) | undefined, changed?: string[]);
20
24
  make(compelled?: boolean): this;
21
25
  makeCallback(compelled?: boolean): void;
26
+ protected abstract initEvent(): void;
22
27
  }
23
28
 
24
29
  // File: src/classes/design/DesignAsyncAbstract.d.ts
25
- import { DesignAbstract } from './DesignAbstract';
26
30
  export declare abstract class DesignAsyncAbstract<T extends Record<string, any>, C extends Record<string, any>> extends DesignAbstract<T, C> {
27
31
  make(compelled?: boolean): this;
28
32
  makeCallback(compelled?: boolean): Promise<void>;
33
+ protected abstract initEvent(): Promise<void>;
29
34
  }
30
35
 
31
36
  // File: src/classes/design/DesignChanged.d.ts
32
37
  export declare class DesignChanged<T extends Record<string, any>> {
38
+ protected readonly props: T;
39
+ protected readonly watch: string[];
33
40
  constructor(props: T, watch?: string[]);
34
41
  is(name: string | string[]): boolean;
35
42
  isChanged(): boolean;
@@ -37,16 +44,13 @@ export declare class DesignChanged<T extends Record<string, any>> {
37
44
  }
38
45
 
39
46
  // File: src/classes/design/DesignComp.d.ts
40
- import { DesignComponents } from './DesignComponents';
41
- import { ConstrComponent, ConstrItem } from '../../types/constructorTypes';
42
47
  export declare class DesignComp<COMP extends ConstrComponent, P extends ConstrItem> extends DesignComponents<COMP, P> {
43
48
  }
44
49
 
45
50
  // File: src/classes/design/DesignComponents.d.ts
46
- import { ComputedRef, VNode } from 'vue';
47
- import { RawChildren, RawSlots } from '../../types/refTypes';
48
- import { ConstrComponent, ConstrComponentMod, ConstrItem } from '../../types/constructorTypes';
49
51
  export declare class DesignComponents<COMP extends ConstrComponent, P extends ConstrItem> {
52
+ protected readonly components: COMP;
53
+ protected readonly modification?: ConstrComponentMod<P> | undefined;
50
54
  protected caching: Record<string, ComputedRef<any>>;
51
55
  constructor(components?: COMP, modification?: ConstrComponentMod<P> | undefined);
52
56
  is<K extends keyof COMP>(name: K): name is K;
@@ -58,9 +62,6 @@ export declare class DesignComponents<COMP extends ConstrComponent, P extends Co
58
62
  }
59
63
 
60
64
  // File: src/classes/design/DesignConstructorAbstract.d.ts
61
- import { ComputedRef, ToRefs, VNode, Ref } from 'vue';
62
- import { DesignComponents } from './DesignComponents';
63
- import { ConstrClass, ConstrClasses, ConstrClassObject, ConstrComponent, ConstrEmit, ConstrExpose, ConstrItem, ConstrOptions, ConstrStyles } from '../../types/constructorTypes';
64
65
  export declare abstract class DesignConstructorAbstract<E extends Element, COMP extends ConstrComponent, EMITS extends ConstrItem, EXPOSE extends ConstrItem, SLOTS extends ConstrItem, CLASSES extends ConstrClasses, P extends ConstrItem> {
65
66
  protected readonly props: Readonly<P>;
66
67
  protected readonly options?: ConstrOptions<COMP, EMITS, P> | undefined;
@@ -96,10 +97,18 @@ export declare abstract class DesignConstructorAbstract<E extends Element, COMP
96
97
  }
97
98
 
98
99
  // File: src/classes/ref/DatetimeRef.d.ts
99
- import { ComputedRef, Ref } from 'vue';
100
- import { Datetime, GeoDate, GeoFirstDay, GeoHours, NumberOrStringOrDate } from '@dxtmisha/functional-basic';
101
- import { RefOrNormal } from '../../types/refTypes';
102
100
  export declare class DatetimeRef {
101
+ protected item: Ref<NumberOrStringOrDate>;
102
+ protected type: Ref<GeoDate>;
103
+ protected code: Ref<string>;
104
+ protected date: Ref<Date>;
105
+ protected datetime: Datetime;
106
+ protected year: Ref<number, number>;
107
+ protected month: Ref<number, number>;
108
+ protected day: Ref<number, number>;
109
+ protected hour: Ref<number, number>;
110
+ protected minute: Ref<number, number>;
111
+ protected second: Ref<number, number>;
103
112
  constructor(date: RefOrNormal<NumberOrStringOrDate>, type?: RefOrNormal<GeoDate>, code?: RefOrNormal<string>);
104
113
  getItem(): Ref<NumberOrStringOrDate>;
105
114
  getDate(): Ref<Date>;
@@ -123,17 +132,13 @@ export declare class EffectScopeGlobal {
123
132
  }
124
133
 
125
134
  // File: src/classes/ref/EventRef.d.ts
126
- import { RefOrNormal } from '../../types/refTypes';
127
- import { ElementOrString, ElementOrWindow, EventItem, EventListenerDetail, EventOptions } from '@dxtmisha/functional-basic';
128
135
  export declare class EventRef<E extends ElementOrWindow, O extends Event, D extends Record<string, any> = Record<string, any>> extends EventItem<E, O, D> {
129
136
  constructor(elementSelector?: RefOrNormal<ElementOrString<E> | undefined>, elementSelectorControl?: RefOrNormal<ElementOrString<HTMLElement>>, type?: string | string[], listener?: EventListenerDetail<O, D>, options?: EventOptions, detail?: D);
130
137
  }
131
138
 
132
139
  // File: src/classes/ref/GeoFlagRef.d.ts
133
- import { ComputedRef } from 'vue';
134
- import { GeoFlag, GeoFlagItem, GeoFlagNational } from '@dxtmisha/functional-basic';
135
- import { RefOrNormal } from '../../types/refTypes';
136
140
  export declare class GeoFlagRef {
141
+ protected flag: ComputedRef<GeoFlag>;
137
142
  constructor(code?: RefOrNormal<string | undefined>);
138
143
  getCode(): string;
139
144
  get(code?: RefOrNormal<string>): ComputedRef<GeoFlagItem | undefined>;
@@ -143,9 +148,6 @@ export declare class GeoFlagRef {
143
148
  }
144
149
 
145
150
  // File: src/classes/ref/GeoIntlRef.d.ts
146
- import { ComputedRef } from 'vue';
147
- import { GeoDate, ItemValue, NumberOrString, NumberOrStringOrDate } from '@dxtmisha/functional-basic';
148
- import { RefOrNormal } from '../../types/refTypes';
149
151
  export declare class GeoIntlRef {
150
152
  constructor(code?: RefOrNormal<string>);
151
153
  display(value?: RefOrNormal<string>, typeOptions?: Intl.DisplayNamesOptions['type'] | Intl.DisplayNamesOptions): ComputedRef<string>;
@@ -173,8 +175,6 @@ export declare class GeoIntlRef {
173
175
  }
174
176
 
175
177
  // File: src/classes/ref/GeoRef.d.ts
176
- import { ComputedRef, Ref } from 'vue';
177
- import { GeoItemFull } from '@dxtmisha/functional-basic';
178
178
  export declare class GeoRef {
179
179
  static get(): Ref<GeoItemFull>;
180
180
  static getCountry(): ComputedRef<string>;
@@ -182,13 +182,24 @@ export declare class GeoRef {
182
182
  static getStandard(): ComputedRef<string>;
183
183
  static getFirstDay(): ComputedRef<string>;
184
184
  static set(code: string): void;
185
+ static setValueDefault(code?: string | (() => string)): void;
185
186
  }
186
187
 
187
188
  // File: src/classes/ref/ListDataRef.d.ts
188
- import { RefOrNormal, RefType } from '../../types/refTypes';
189
- import { ListDataFull, ListDataItem, ListList, ListListInput, ListNames, ListSelectedItem, ListSelectedList } from '../../types/listTypes';
190
- import { ComputedRef } from 'vue';
191
189
  export declare class ListDataRef {
190
+ protected readonly list: RefOrNormal<ListListInput | undefined>;
191
+ protected readonly focus?: RefType<ListSelectedItem | undefined> | undefined;
192
+ protected readonly highlight?: RefType<string | undefined> | undefined;
193
+ protected readonly highlightLengthStart?: RefType<number | undefined> | undefined;
194
+ protected readonly filterMode?: RefType<boolean | undefined> | undefined;
195
+ protected readonly selected?: RefType<ListSelectedList | undefined> | undefined;
196
+ protected readonly keyValue?: RefType<string | undefined> | undefined;
197
+ protected readonly keyLabel?: RefType<string | undefined> | undefined;
198
+ protected readonly lite?: RefType<number | undefined> | undefined;
199
+ protected readonly min: RefOrNormal<number | string | undefined>;
200
+ protected readonly max: RefOrNormal<number | string | undefined>;
201
+ protected readonly parent?: string | undefined;
202
+ protected subList: Record<any, ListDataRef>;
192
203
  constructor(list: RefOrNormal<ListListInput | undefined>, focus?: RefType<ListSelectedItem | undefined> | undefined, highlight?: RefType<string | undefined> | undefined, highlightLengthStart?: RefType<number | undefined> | undefined, filterMode?: RefType<boolean | undefined> | undefined, selected?: RefType<ListSelectedList | undefined> | undefined, keyValue?: RefType<string | undefined> | undefined, keyLabel?: RefType<string | undefined> | undefined, lite?: RefType<number | undefined> | undefined, min?: RefOrNormal<number | string | undefined>, max?: RefOrNormal<number | string | undefined>, parent?: string | undefined);
193
204
  readonly data: ComputedRef<ListList>;
194
205
  readonly liteData: ComputedRef<ListList>;
@@ -233,8 +244,6 @@ export declare class ListDataRef {
233
244
  }
234
245
 
235
246
  // File: src/classes/ref/RouterItemRef.d.ts
236
- import { RouteLocationRaw, Router } from 'vue-router';
237
- import { ConstrHrefProps } from '../../types/constructorTypes';
238
247
  export declare class RouterItemRef {
239
248
  static get(): Router;
240
249
  static getLink(name: string, params?: any, query?: any): string | undefined;
@@ -246,7 +255,6 @@ export declare class RouterItemRef {
246
255
  }
247
256
 
248
257
  // File: src/classes/ref/ScrollbarWidthRef.d.ts
249
- import { Ref, ComputedRef } from 'vue';
250
258
  export declare class ScrollbarWidthRef {
251
259
  readonly item: Ref<boolean | undefined, boolean | undefined>;
252
260
  readonly width: Ref<number, number>;
@@ -255,45 +263,30 @@ export declare class ScrollbarWidthRef {
255
263
  }
256
264
 
257
265
  // File: src/composables/ref/useApiAsyncRef.d.ts
258
- import { ApiInstance, ApiData, ApiDataValidation, ApiErrorStorageList } from '@dxtmisha/functional-basic';
259
- import { UseApiRef } from './useApiRef';
260
- import { RefOrNormal, RefType } from '../../types/refTypes';
261
- import { ApiOptions } from '../../types/apiTypes';
262
266
  export declare function useApiAsyncRef<R, T = R>(path?: RefOrNormal<string | undefined>, options?: ApiOptions, reactivity?: boolean, conditions?: RefType<boolean>, transformation?: (data: T, isResponseContractValid?: ApiDataValidation) => ApiData<R>, validateResponseContract?: (data: T) => ApiDataValidation, errorContract?: ApiErrorStorageList, unmounted?: boolean, apiInstance?: ApiInstance): UseApiRef<R>;
263
267
 
264
268
  // File: src/composables/ref/useApiDelete.d.ts
265
- import { ApiData, ApiFetch } from '@dxtmisha/functional-basic';
266
- import { UseApiRequestSetup } from './useApiRequest';
267
- import { Ref } from 'vue';
268
- export interface UseApiDeleteSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {
269
- }
269
+ export interface UseApiDeleteSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {}
270
270
  export declare function useApiDelete<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiDeleteSetup<T, Request, Return>): {
271
271
  loading: Ref<boolean, boolean>;
272
272
  send(request?: Request | undefined): Promise<Return | undefined>;
273
273
  };
274
274
 
275
275
  // File: src/composables/ref/useApiGet.d.ts
276
- import { ApiData, ApiFetch } from '@dxtmisha/functional-basic';
277
- import { UseApiRequestSetup } from './useApiRequest';
278
- import { Ref } from 'vue';
279
- export interface UseApiGetSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {
280
- }
276
+ export interface UseApiGetSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {}
281
277
  export declare function useApiGet<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiGetSetup<T, Request, Return>): {
282
278
  loading: Ref<boolean, boolean>;
283
279
  send(request?: Request | undefined): Promise<Return | undefined>;
284
280
  };
285
281
 
286
282
  // File: src/composables/ref/useApiManagementAsyncRef.d.ts
287
- import { ApiInstance, ArrayToItem, FormattersListColumns, FormattersOptionsList, SearchColumns, ApiDataValidation, SearchFormatList, ApiData, ApiErrorItem, ApiFetch } from '@dxtmisha/functional-basic';
288
- import { ApiManagementGet, ApiManagementRequest, ApiManagementSearch, ApiManagementValue } from '../../types/apiTypes';
289
- import { ComputedRef, Ref } from 'vue';
290
283
  export declare function useApiManagementAsyncRef<Return extends ApiManagementValue, FormattersOptions extends FormattersOptionsList, Post extends Record<string, any>, Put extends Record<string, any>, Delete extends Record<string, any>, Type extends ApiManagementValue = Return, Item extends ArrayToItem<Return> = ArrayToItem<Return>, ItemFormatters extends FormattersListColumns<Item, FormattersOptions>[number] = FormattersListColumns<Item, FormattersOptions>[number], Columns extends SearchColumns<ItemFormatters> = []>(propsGet: ApiManagementGet<Return, Type>, formattersOptions?: FormattersOptions, searchOptions?: ApiManagementSearch<Item, Columns>, postRequest?: ApiManagementRequest<Post>, putRequest?: ApiManagementRequest<Put>, deleteRequest?: ApiManagementRequest<Delete>, action?: () => Promise<void> | void, apiInstance?: ApiInstance): {
291
284
  isValid: ComputedRef<boolean>;
292
285
  isResponseContractValid: ComputedRef<boolean>;
293
- responseValidationResult: ComputedRef<ApiDataValidation | undefined>;
286
+ responseValidationResult: ComputedRef< ApiDataValidation | undefined>;
294
287
  list: ComputedRef<SearchFormatList<ItemFormatters, Columns>>;
295
- readonly data: ComputedRef<ApiData<Return> | undefined>;
296
- errorItem: ComputedRef<ApiErrorItem | undefined>;
288
+ readonly data: ComputedRef< ApiData<Return> | undefined>;
289
+ errorItem: ComputedRef< ApiErrorItem | undefined>;
297
290
  readonly length: ComputedRef<number>;
298
291
  lengthData: ComputedRef<number>;
299
292
  starting: ComputedRef<boolean>;
@@ -309,22 +302,19 @@ export declare function useApiManagementAsyncRef<Return extends ApiManagementVal
309
302
  initSsr: () => void;
310
303
  reset: () => Promise<void>;
311
304
  abort: () => void;
312
- sendPost: (request?: ApiFetch["request"]) => Promise<ApiData<Post> | undefined>;
313
- sendPut: (request?: ApiFetch["request"]) => Promise<ApiData<Put> | undefined>;
314
- sendDelete: (request?: ApiFetch["request"]) => Promise<ApiData<Delete> | undefined>;
305
+ sendPost: (request?: ApiFetch["request"]) => Promise< ApiData<Post> | undefined>;
306
+ sendPut: (request?: ApiFetch["request"]) => Promise< ApiData<Put> | undefined>;
307
+ sendDelete: (request?: ApiFetch["request"]) => Promise< ApiData<Delete> | undefined>;
315
308
  };
316
309
 
317
310
  // File: src/composables/ref/useApiManagementRef.d.ts
318
- import { Ref, ComputedRef } from 'vue';
319
- import { FormattersOptionsList, ApiData, ApiInstance, ArrayToItem, SearchColumns, SearchFormatList, FormattersListColumns, ApiFetch, ApiDataValidation, ApiErrorItem } from '@dxtmisha/functional-basic';
320
- import { ApiManagementGet, ApiManagementRequest, ApiManagementSearch, ApiManagementValue } from '../../types/apiTypes';
321
311
  export declare function useApiManagementRef<Return extends ApiManagementValue, FormattersOptions extends FormattersOptionsList, Post extends Record<string, any>, Put extends Record<string, any>, Delete extends Record<string, any>, Type extends ApiManagementValue = Return, Item extends ArrayToItem<Return> = ArrayToItem<Return>, ItemFormatters extends FormattersListColumns<Item, FormattersOptions>[number] = FormattersListColumns<Item, FormattersOptions>[number], Columns extends SearchColumns<ItemFormatters> = []>(propsGet: ApiManagementGet<Return, Type>, formattersOptions?: FormattersOptions, searchOptions?: ApiManagementSearch<Item, Columns>, postRequest?: ApiManagementRequest<Post>, putRequest?: ApiManagementRequest<Put>, deleteRequest?: ApiManagementRequest<Delete>, action?: () => Promise<void> | void, apiInstance?: ApiInstance): {
322
312
  isValid: ComputedRef<boolean>;
323
313
  isResponseContractValid: ComputedRef<boolean>;
324
- responseValidationResult: ComputedRef<ApiDataValidation | undefined>;
314
+ responseValidationResult: ComputedRef< ApiDataValidation | undefined>;
325
315
  list: ComputedRef<SearchFormatList<ItemFormatters, Columns>>;
326
316
  readonly data: ComputedRef<ApiData<Return> | undefined>;
327
- errorItem: ComputedRef<ApiErrorItem | undefined>;
317
+ errorItem: ComputedRef< ApiErrorItem | undefined>;
328
318
  readonly length: ComputedRef<number>;
329
319
  lengthData: ComputedRef<number>;
330
320
  starting: ComputedRef<boolean>;
@@ -346,32 +336,20 @@ export declare function useApiManagementRef<Return extends ApiManagementValue, F
346
336
  };
347
337
 
348
338
  // File: src/composables/ref/useApiPost.d.ts
349
- import { ApiData, ApiFetch } from '@dxtmisha/functional-basic';
350
- import { UseApiRequestSetup } from './useApiRequest';
351
- import { Ref } from 'vue';
352
- export interface UseApiPostSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {
353
- }
339
+ export interface UseApiPostSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {}
354
340
  export declare function useApiPost<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiPostSetup<T, Request, Return>): {
355
341
  loading: Ref<boolean, boolean>;
356
342
  send(request?: Request | undefined): Promise<Return | undefined>;
357
343
  };
358
344
 
359
345
  // File: src/composables/ref/useApiPut.d.ts
360
- import { ApiData, ApiFetch } from '@dxtmisha/functional-basic';
361
- import { UseApiRequestSetup } from './useApiRequest';
362
- import { Ref } from 'vue';
363
- export interface UseApiPutSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {
364
- }
346
+ export interface UseApiPutSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {}
365
347
  export declare function useApiPut<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiPutSetup<T, Request, Return>): {
366
348
  loading: Ref<boolean, boolean>;
367
349
  send(request?: Request | undefined): Promise<Return | undefined>;
368
350
  };
369
351
 
370
352
  // File: src/composables/ref/useApiRef.d.ts
371
- import { ComputedRef, Ref } from 'vue';
372
- import { ApiInstance, ApiData, ApiDataValidation, ApiErrorStorageList, ApiErrorItem } from '@dxtmisha/functional-basic';
373
- import { ApiOptions } from '../../types/apiTypes';
374
- import { RefOrNormal, RefType } from '../../types/refTypes';
375
353
  export interface UseApiRef<R> {
376
354
  data: ComputedRef<ApiData<R> | undefined>;
377
355
  item: Ref<ApiData<R> | undefined>;
@@ -396,10 +374,6 @@ export declare function useApiRef<R, T = R>(path?: RefOrNormal<string | undefine
396
374
  export declare const setApiRefGlobalConditions: (conditions: RefType<any>) => void;
397
375
 
398
376
  // File: src/composables/ref/useApiRequest.d.ts
399
- import { ApiInstance, ApiMethodItem, ApiData, ApiFetch, ApiErrorStorageList, ApiDataValidation } from '@dxtmisha/functional-basic';
400
- import { ApiOptions } from '../../types/apiTypes';
401
- import { RefOrNormal } from '../../types/refTypes';
402
- import { Ref } from 'vue';
403
377
  export interface UseApiRequestSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> {
404
378
  path?: RefOrNormal<string | undefined>;
405
379
  method?: ApiMethodItem;
@@ -418,153 +392,54 @@ export declare function useApiRequest<T, Request extends ApiFetch['request'] = A
418
392
  };
419
393
 
420
394
  // File: src/composables/ref/useBroadcastValueRef.d.ts
421
- import { Ref } from 'vue';
422
395
  export declare function useBroadcastValueRef<T>(name: string, defaultValue?: T | string | (() => (T | string))): Ref<T | string | undefined>;
423
396
 
424
397
  // File: src/composables/ref/useCookieRef.d.ts
425
- import { Ref } from 'vue';
426
- import { CookieOptions } from '@dxtmisha/functional-basic';
427
398
  export declare function useCookieRef<T>(name: string, defaultValue?: T | string | (() => (T | string)), options?: CookieOptions): Ref<T | string | undefined>;
428
399
 
429
400
  // File: src/composables/ref/useFormattersRef.d.ts
430
- import { FormattersListProp, FormattersOptionsList, FormattersReturn } from '@dxtmisha/functional-basic';
431
- import { RefType } from '../../types/refTypes';
432
- import { ComputedRef } from 'vue';
433
401
  export declare function useFormattersRef<Options extends FormattersOptionsList = FormattersOptionsList, List extends FormattersListProp = FormattersListProp>(list: RefType<List | undefined>, options: Options): {
434
402
  listFormat: ComputedRef<FormattersReturn<List, Options>>;
435
403
  length: ComputedRef<number>;
436
404
  };
437
405
 
438
406
  // File: src/composables/ref/useGeoIntlRef.d.ts
439
- import { GeoIntlRef } from '../../classes/ref/GeoIntlRef';
440
407
  export declare function useGeoIntlRef(): GeoIntlRef;
441
408
 
442
409
  // File: src/composables/ref/useHashRef.d.ts
443
- import { ShallowRef } from 'vue';
444
410
  export declare function useHashRef<T>(name: string, defaultValue?: T | (() => T)): ShallowRef<T>;
445
411
 
446
412
  // File: src/composables/ref/useLazyItemByMarginRef.d.ts
447
- import { RefType } from '../../types/refTypes';
448
- export declare const useLazyItemByMarginRef: (element: RefType<HTMLElement | undefined>, rootMargin: string) => {
449
- lazyItemStatus: any;
450
- readonly lazyItem: any;
451
- };
413
+ export type LazyItemByMargin = { rootMargin: string; item: any; };
414
+ export declare const useLazyItemByMarginRef: (element: RefType<HTMLElement | undefined>, rootMargin: string) => { lazyItemStatus: any; readonly lazyItem: any; };
452
415
 
453
416
  // File: src/composables/ref/useLazyRef.d.ts
454
- import { Ref, ShallowRef } from 'vue';
455
- export declare const useLazyRef: (options?: IntersectionObserverInit) => {
456
- intersectionObserver: IntersectionObserver | undefined;
457
- getItem(element: HTMLElement): any;
458
- addLazyItem(element: Ref<HTMLElement | undefined>): ShallowRef<boolean, boolean>;
459
- removeLazyItem: (element?: HTMLElement) => void;
460
- disconnectLazy: () => void | undefined;
461
- };
417
+ export type LazyItem = { status: ShallowRef<boolean>; ratio: ShallowRef<number>; entry: ShallowRef<IntersectionObserverEntry | undefined>; stopWatch: () => void; };
418
+ export type LazyList = Record<string, LazyItem>;
419
+ export declare const useLazyRef: (options?: IntersectionObserverInit) => { intersectionObserver: IntersectionObserver | undefined; getItem(element: HTMLElement): LazyItem; addLazyItem(element: Ref<HTMLElement | undefined>): ShallowRef<boolean, boolean>; removeLazyItem: (element?: HTMLElement) => void; disconnectLazy: () => void | undefined; };
462
420
 
463
421
  // File: src/composables/ref/useLoadingRef.d.ts
464
- import { ShallowRef } from 'vue';
465
422
  export declare function useLoadingRef(): ShallowRef<boolean, boolean>;
466
423
 
467
424
  // File: src/composables/ref/useMeta.d.ts
468
- import { MetaRobots, MetaStatic } from '@dxtmisha/functional-basic';
469
- import { Ref } from 'vue';
470
- export declare const useMeta: () => Readonly<{
471
- meta: typeof MetaStatic;
472
- title: Ref<string, string>;
473
- keyword: Ref<string, string>;
474
- description: Ref<string, string>;
475
- author: Ref<string, string>;
476
- image: Ref<string, string>;
477
- canonical: Ref<string, string>;
478
- robots: Ref<MetaRobots, MetaRobots>;
479
- siteName: Ref<string, string>;
480
- getHtmlMeta: () => string;
481
- sync: () => void;
482
- update: () => void;
483
- updateSsr: () => void;
484
- setTitle: (value: string) => void;
485
- setKeywords: (value: string) => void;
486
- setDescription: (value: string) => void;
487
- setAuthor: (value: string) => void;
488
- setImage: (value: string) => void;
489
- setCanonical: (value: string) => void;
490
- setRobots: (value: MetaRobots) => void;
491
- setSiteName: (value: string) => void;
492
- setSuffix: (suffix: string) => typeof MetaStatic;
493
- }> & {
494
- init(): Readonly<{
495
- meta: typeof MetaStatic;
496
- title: Ref<string, string>;
497
- keyword: Ref<string, string>;
498
- description: Ref<string, string>;
499
- author: Ref<string, string>;
500
- image: Ref<string, string>;
501
- canonical: Ref<string, string>;
502
- robots: Ref<MetaRobots, MetaRobots>;
503
- siteName: Ref<string, string>;
504
- getHtmlMeta: () => string;
505
- sync: () => void;
506
- update: () => void;
507
- updateSsr: () => void;
508
- setTitle: (value: string) => void;
509
- setKeywords: (value: string) => void;
510
- setDescription: (value: string) => void;
511
- setAuthor: (value: string) => void;
512
- setImage: (value: string) => void;
513
- setCanonical: (value: string) => void;
514
- setRobots: (value: MetaRobots) => void;
515
- setSiteName: (value: string) => void;
516
- setSuffix: (suffix: string) => typeof MetaStatic;
517
- }>;
518
- destroyExecute?(): void;
519
- }>;
425
+ export declare const useMeta: () => Readonly<{ meta: typeof MetaStatic; title: Ref<string, string>; keyword: Ref<string, string>; description: Ref<string, string>; author: Ref<string, string>; image: Ref<string, string>; canonical: Ref<string, string>; robots: Ref<MetaRobots, MetaRobots>; siteName: Ref<string, string>; getHtmlMeta: () => string; sync: () => void; update: () => void; updateSsr: () => void; setTitle: (value: string) => void; setKeywords: (value: string) => void; setDescription: (value: string) => void; setAuthor: (value: string) => void; setImage: (value: string) => void; setCanonical: (value: string) => void; setRobots: (value: MetaRobots) => void; setSiteName: (value: string) => void; setSuffix: (suffix: string) => typeof MetaStatic; } & { init(): Readonly<any>; destroyExecute?(): void; }>;
520
426
 
521
427
  // File: src/composables/ref/useRouterList.d.ts
522
- import { Ref, ComputedRef } from 'vue';
523
- import { NumberOrString } from '@dxtmisha/functional-basic';
524
- import { ConstrBind } from '../../types/constructorTypes';
525
- import { ListDataBasic } from '../../types/listTypes';
526
- import { RefType } from '../../types/refTypes';
527
- export declare const useRouterList: <T extends ListDataBasic>(list: RefType<ConstrBind<T>[] | undefined>, selected?: Ref<string> | string, hasTo?: boolean) => {
528
- item: ComputedRef<T | undefined>;
529
- selected: Ref<string, string>;
530
- label: ComputedRef<NumberOrString>;
531
- list: ComputedRef<ConstrBind<T>[]>;
532
- to: (name?: string) => void;
533
- toMain(): void;
534
- };
428
+ export declare const useRouterList: <T extends ListDataBasic>(list: RefType<ConstrBind<T>[] | undefined>, selected?: Ref<string> | string, hasTo?: boolean) => { item: ComputedRef<T | undefined>; selected: Ref<string, string>; label: ComputedRef<NumberOrString>; list: ComputedRef<ConstrBind<T>[]>; to: (name?: string) => void; toMain(): void; };
535
429
 
536
430
  // File: src/composables/ref/useSearchRef.d.ts
537
- import { Ref, ComputedRef } from 'vue';
538
- import { SearchColumns, SearchFormatList, SearchItem, SearchOptions } from '@dxtmisha/functional-basic';
539
- import { SearchListInput } from '../../types/searchTypes';
540
- export declare function useSearchRef<T extends SearchItem, K extends SearchColumns<T>>(list: SearchListInput<T>, columns: K, value?: Ref<string>, options?: SearchOptions): {
541
- isSearch: ComputedRef<boolean>;
542
- search: Ref<string, string>;
543
- loading: Ref<boolean, boolean>;
544
- listSearch: ComputedRef<SearchFormatList<T, K>>;
545
- length: ComputedRef<number>;
546
- };
431
+ export declare function useSearchRef<T extends SearchItem, K extends SearchColumns<T>>(list: SearchListInput<T>, columns: K, value?: Ref<string>, options?: SearchOptions): { isSearch: ComputedRef<boolean>; search: Ref<string, string>; loading: Ref<boolean, boolean>; listSearch: ComputedRef<SearchFormatList<T, K>>; length: ComputedRef<number>; };
547
432
 
548
433
  // File: src/composables/ref/useSearchValueRef.d.ts
549
- import { Ref } from 'vue';
550
- import { SearchList, SearchColumns, SearchItem } from '@dxtmisha/functional-basic';
551
- export declare function useSearchValueRef<T extends SearchItem, K extends SearchColumns<T>>(item: SearchList<T, K>, value?: Ref<string>): {
552
- search: Ref<string, string>;
553
- searchDelay: Ref<string, string>;
554
- loading: Ref<boolean, boolean>;
555
- };
434
+ export declare function useSearchValueRef<T extends SearchItem, K extends SearchColumns<T>>(item: SearchList<T, K>, value?: Ref<string>): { search: Ref<string, string>; searchDelay: Ref<string, string>; loading: Ref<boolean, boolean>; };
556
435
 
557
436
  // File: src/composables/ref/useSessionRef.d.ts
558
- import { Ref } from 'vue';
559
437
  export declare function useSessionRef<T>(name: string, defaultValue?: T | (() => T)): Ref<T | undefined>;
560
438
 
561
439
  // File: src/composables/ref/useStorageRef.d.ts
562
- import { Ref } from 'vue';
563
440
  export declare function useStorageRef<T>(name: string, defaultValue?: T | (() => T), cache?: number): Ref<T | undefined>;
564
441
 
565
442
  // File: src/composables/ref/useTranslateRef.d.ts
566
- import { ShallowRef } from 'vue';
567
- import { TranslateInstance, TranslateList } from '@dxtmisha/functional-basic';
568
443
  export declare function useTranslateRef<T extends (string | string[])[]>(names: T, translateInstance?: TranslateInstance): ShallowRef<TranslateList<T>>;
569
444
  export declare const t: <T extends string[]>(names: T) => ShallowRef<TranslateList<T>>;
570
445
 
@@ -575,219 +450,77 @@ export declare const uiMakeFlags: () => void;
575
450
  export * from '@dxtmisha/functional-basic';
576
451
 
577
452
  // File: src/functions/computedAsync.d.ts
578
- import { ComputedRef, DebuggerOptions } from 'vue';
579
453
  export declare function computedAsync<R>(getter: (() => Promise<R>) | (() => R) | R, initialState?: (() => R) | R, ignore?: R, debugOptions?: DebuggerOptions): ComputedRef<R | undefined>;
580
454
 
581
455
  // File: src/functions/computedByLanguage.d.ts
582
- import { ComputedGetter, ComputedRef, DebuggerOptions } from 'vue';
583
456
  export declare function computedByLanguage<T, R extends (T | undefined) = T | undefined>(getter: ComputedGetter<R>, getterNone?: R | (() => R), conditions?: () => boolean, debugOptions?: DebuggerOptions): ComputedRef<R>;
584
457
 
585
458
  // File: src/functions/computedEternity.d.ts
586
- import { Ref } from 'vue';
587
459
  export declare function computedEternity<T>(getter: () => Promise<T> | T, initialState?: (() => T) | T): Ref<T, T>;
588
460
 
589
461
  // File: src/functions/dxtFunctionalPlugin.d.ts
590
- import { Plugin } from 'vue';
591
- import { ApiConfig, ErrorCenterCauseList, ErrorCenterHandlerList, IconsConfig, TranslateConfig } from '@dxtmisha/functional-basic';
592
- import { Router } from 'vue-router';
593
- export interface FunctionalPluginOptions {
594
- api?: ApiConfig;
595
- translate?: TranslateConfig;
596
- metaSuffix?: string;
597
- icons?: IconsConfig;
598
- router?: Router;
599
- errorCauses?: ErrorCenterCauseList;
600
- errorHandlers?: ErrorCenterHandlerList;
601
- }
462
+ export interface FunctionalPluginOptions { api?: ApiConfig; translate?: TranslateConfig; location?: string | (() => string); metaSuffix?: string; icons?: IconsConfig; router?: Router; errorCauses?: ErrorCenterCauseList; errorHandlers?: ErrorCenterHandlerList; }
602
463
  export declare const dxtFunctionalPlugin: Plugin;
603
464
 
604
465
  // File: src/functions/executeUse.d.ts
605
- export declare enum ExecuteUseType {
606
- global = "global",
607
- provide = "provide",
608
- local = "local"
609
- }
610
- export type ExecuteUseReturn<R> = Readonly<R & {
611
- init(): Readonly<R>;
612
- destroyExecute?(): void;
613
- }>;
466
+ export declare enum ExecuteUseType { global = "global", provide = "provide", local = "local" }
467
+ export type ExecuteUseReturn<R> = Readonly<R & { init(): Readonly<R>; destroyExecute?(): void; }>;
614
468
  export declare function executeUse<R, O extends any[], RI extends ExecuteUseReturn<R> = ExecuteUseReturn<R>>(callback: (...args: O) => R, type?: ExecuteUseType): ((...args: O) => RI) | (() => RI);
615
- export declare function executeUseGlobal<R>(callback: () => R): any;
616
- export declare function executeUseProvide<R, O extends any[]>(callback: (...args: O) => R): any;
617
- export declare function executeUseLocal<R, O extends any[]>(callback: (...args: O) => R): any;
469
+ export declare function executeUseGlobal<R>(callback: () => R): (() => Readonly<any>) | (() => Readonly<any>);
470
+ export declare function executeUseProvide<R, O extends any[]>(callback: (...args: O) => R): ((...args: O) => Readonly<any>) | (() => Readonly<any>);
471
+ export declare function executeUseLocal<R, O extends any[]>(callback: (...args: O) => R): ((...args: O) => Readonly<any>) | (() => Readonly<any>);
618
472
  export declare function executeUseGlobalInit(): void;
619
473
 
620
474
  // File: src/functions/getInject.d.ts
621
475
  export declare function getInject<T>(name: string): T | undefined;
622
476
 
623
477
  // File: src/functions/getOptions.d.ts
624
- import { ApiFetch } from '@dxtmisha/functional-basic';
625
- import { ApiOptions } from '../types/apiTypes';
626
- import { RefOrNormal } from '../types/refTypes';
627
478
  export declare const getOptions: (options?: ApiOptions) => RefOrNormal<ApiFetch>;
628
479
 
629
480
  // File: src/functions/ref/executeFunctionRef.d.ts
630
- import { RefOrNormalOrFunction } from '../../types/refTypes';
631
481
  export declare function executeFunctionRef<T>(data: RefOrNormalOrFunction<T>): T;
632
482
 
633
483
  // File: src/functions/ref/getApiErrorRef.d.ts
634
- import { ComputedRef } from 'vue';
635
- import { ApiData, ApiErrorItem } from '@dxtmisha/functional-basic';
636
- import { RefType } from '../../types/refTypes';
637
484
  export declare function getApiErrorRef<R>(data: RefType<ApiData<R> | undefined>): ComputedRef<ApiErrorItem | undefined>;
638
485
 
639
486
  // File: src/functions/ref/getBindRef.d.ts
640
- import { ComputedRef } from 'vue';
641
- import { ItemList } from '@dxtmisha/functional-basic';
642
- import { RefOrNormal } from '../../types/refTypes';
643
487
  export declare function getBindRef<T, R extends ItemList>(value: RefOrNormal<T | R> | undefined, nameExtra?: RefOrNormal<ItemList> | string, name?: string): ComputedRef<R>;
644
488
 
645
489
  // File: src/functions/ref/getRef.d.ts
646
- import { RefOrNormal } from '../../types/refTypes';
647
490
  export declare function getRef<T>(item: RefOrNormal<T>): T;
648
491
 
649
492
  // File: src/functions/ref/render.d.ts
650
- import { VNode } from 'vue';
651
- import { ItemList } from '@dxtmisha/functional-basic';
652
- import { RawChildren, RawSlots } from '../../types/refTypes';
653
493
  export declare function render<T extends ItemList>(name: string | any, props?: T, children?: RawChildren | RawSlots, index?: string): VNode;
654
494
 
655
495
  // File: src/functions/ref/setRef.d.ts
656
- import { Ref } from 'vue';
657
496
  export declare function setRef<T>(item: Ref<T>, value: T): void;
658
497
 
659
498
  // File: src/functions/ref/toRefItem.d.ts
660
- import { Ref } from 'vue';
661
- import { RefOrNormal } from '../../types/refTypes';
662
499
  export declare function toRefItem<T>(item: RefOrNormal<T>): Ref<T>;
663
500
 
664
501
  // File: src/functions/render/getBind.d.ts
665
- import { ItemList } from '@dxtmisha/functional-basic';
666
- import { ConstrBind } from '../../types/constructorTypes';
667
502
  export declare function getBind<T, R extends ItemList>(value: T | R | undefined | null, nameExtra?: ItemList | string, name?: string, except?: boolean): ConstrBind<R>;
668
503
 
669
504
  // File: src/functions/render/getClassName.d.ts
670
- import { ItemList } from '@dxtmisha/functional-basic';
671
505
  export declare function getClassName<T extends ItemList>(props?: T): string | undefined;
672
506
 
673
507
  // File: src/functions/render/getIndexForRender.d.ts
674
- import { ItemList } from '@dxtmisha/functional-basic';
675
508
  export declare function getIndexForRender<T extends ItemList>(name: string | any, props?: T, index?: string): string | undefined;
676
509
 
677
510
  // File: src/functions/toBind.d.ts
678
- import { ItemList } from '@dxtmisha/functional-basic';
679
- import { ConstrBind } from '../types/constructorTypes';
680
511
  export declare function toBind<R extends ItemList = ItemList>(extra: ItemList, value: ItemList): ConstrBind<R>;
681
512
 
682
513
  // File: src/functions/toBinds.d.ts
683
- import { ItemList } from '@dxtmisha/functional-basic';
684
- import { ConstrBind } from '../types/constructorTypes';
685
514
  export declare function toBinds<R extends ItemList = ItemList>(...values: (ItemList | undefined)[]): ConstrBind<R>;
686
515
 
687
- // File: src/library.d.ts
688
- export * from './classes/design/DesignAbstract';
689
- export * from './classes/design/DesignAsyncAbstract';
690
- export * from './classes/design/DesignChanged';
691
- export * from './classes/design/DesignComp';
692
- export * from './classes/design/DesignComponents';
693
- export * from './classes/design/DesignConstructorAbstract';
694
- export * from './classes/ref/DatetimeRef';
695
- export * from './classes/ref/EffectScopeGlobal';
696
- export * from './classes/ref/EventRef';
697
- export * from './classes/ref/GeoFlagRef';
698
- export * from './classes/ref/GeoIntlRef';
699
- export * from './classes/ref/GeoRef';
700
- export * from './classes/ref/ListDataRef';
701
- export * from './classes/ref/RouterItemRef';
702
- export * from './classes/ref/ScrollbarWidthRef';
703
- export * from './composables/ref/useApiAsyncRef';
704
- export * from './composables/ref/useApiDelete';
705
- export * from './composables/ref/useApiGet';
706
- export * from './composables/ref/useApiManagementAsyncRef';
707
- export * from './composables/ref/useApiManagementRef';
708
- export * from './composables/ref/useApiPost';
709
- export * from './composables/ref/useApiPut';
710
- export * from './composables/ref/useApiRef';
711
- export * from './composables/ref/useApiRequest';
712
- export * from './composables/ref/useBroadcastValueRef';
713
- export * from './composables/ref/useCookieRef';
714
- export * from './composables/ref/useFormattersRef';
715
- export * from './composables/ref/useGeoIntlRef';
716
- export * from './composables/ref/useHashRef';
717
- export * from './composables/ref/useLazyItemByMarginRef';
718
- export * from './composables/ref/useLazyRef';
719
- export * from './composables/ref/useLoadingRef';
720
- export * from './composables/ref/useMeta';
721
- export * from './composables/ref/useRouterList';
722
- export * from './composables/ref/useSearchRef';
723
- export * from './composables/ref/useSearchValueRef';
724
- export * from './composables/ref/useSessionRef';
725
- export * from './composables/ref/useStorageRef';
726
- export * from './composables/ref/useTranslateRef';
727
- export * from './functions/basic';
728
- export * from './functions/computedAsync';
729
- export * from './functions/computedByLanguage';
730
- export * from './functions/computedEternity';
731
- export * from './functions/dxtFunctionalPlugin';
732
- export * from './functions/executeUse';
733
- export * from './functions/getInject';
734
- export * from './functions/getOptions';
735
- export * from './functions/ref/executeFunctionRef';
736
- export * from './functions/ref/getApiErrorRef';
737
- export * from './functions/ref/getBindRef';
738
- export * from './functions/ref/getRef';
739
- export * from './functions/ref/render';
740
- export * from './functions/ref/setRef';
741
- export * from './functions/ref/toRefItem';
742
- export * from './functions/render/getBind';
743
- export * from './functions/render/getClassName';
744
- export * from './functions/render/getIndexForRender';
745
- export * from './functions/toBind';
746
- export * from './functions/toBinds';
747
- export * from './types/apiTypes';
748
- export * from './types/constructorTypes';
749
- export * from './types/listTypes';
750
- export * from './types/refTypes';
751
- export * from './types/searchTypes';
752
-
753
516
  // File: src/types/apiTypes.d.ts
754
- import { ApiData, ApiDataValidation, ApiDefaultValue, ApiErrorStorageList, ApiFetch, ApiMethodItem, SearchColumns, SearchItem, SearchOptions } from '@dxtmisha/functional-basic';
755
- import { RefOrNormal, RefType } from './refTypes';
756
- import { Ref } from 'vue';
757
517
  export type ApiOptions = ApiMethodItem | RefOrNormal<ApiFetch>;
758
518
  export type ApiManagementValue = ApiDefaultValue | ApiDefaultValue[];
759
- export type ApiManagementGet<Return extends ApiManagementValue, Type extends ApiManagementValue = Return> = {
760
- path?: RefOrNormal<string | undefined>;
761
- options?: ApiOptions;
762
- reactivity?: boolean;
763
- conditions?: RefType<boolean>;
764
- transformation?: (data: Type, isResponseContractValid?: ApiDataValidation) => ApiData<Return>;
765
- validateResponseContract?: (data: Type) => ApiDataValidation;
766
- errorContract?: ApiErrorStorageList;
767
- typeData?: ((data: Return) => boolean) | any;
768
- unmounted?: boolean;
769
- skeleton?: () => Return;
770
- };
771
- export type ApiManagementSearch<T extends SearchItem, K extends SearchColumns<T>> = {
772
- columns: K;
773
- value?: Ref<string>;
774
- options?: SearchOptions;
775
- };
776
- export type ApiManagementRequest<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> = {
777
- path?: RefOrNormal<string | undefined>;
778
- action?: (data: Return | undefined) => Promise<void> | void;
779
- transformation?: (data: T) => Return;
780
- validateRequestContract?: (data: Request) => ApiDataValidation & Return;
781
- validateResponseContract?: (data: T) => ApiDataValidation & Return;
782
- errorContract?: ApiErrorStorageList;
783
- toData?: boolean;
784
- options?: ApiOptions;
785
- };
519
+ export type ApiManagementGet<Return extends ApiManagementValue, Type extends ApiManagementValue = Return> = { path?: RefOrNormal<string | undefined>; options?: ApiOptions; reactivity?: boolean; conditions?: RefType<boolean>; transformation?: (data: Type, isResponseContractValid?: ApiDataValidation) => ApiData<Return>; validateResponseContract?: (data: Type) => ApiDataValidation; errorContract?: ApiErrorStorageList; typeData?: ((data: Return) => boolean) | any; unmounted?: boolean; skeleton?: () => Return; };
520
+ export type ApiManagementSearch<T extends SearchItem, K extends SearchColumns<T>> = { columns: K; value?: Ref<string>; options?: SearchOptions; };
521
+ export type ApiManagementRequest<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> = { path?: RefOrNormal<string | undefined>; action?: (data: Return | undefined) => Promise<void> | void; transformation?: (data: T) => Return; validateRequestContract?: (data: Request) => ApiDataValidation & Return; validateResponseContract?: (data: T) => ApiDataValidation & Return; errorContract?: ApiErrorStorageList; toData?: boolean; options?: ApiOptions; };
786
522
 
787
523
  // File: src/types/constructorTypes.d.ts
788
- import { Ref, PropType, ComputedRef } from 'vue';
789
- import { Undefined } from '@dxtmisha/functional-basic';
790
- import { RefOrNormal, RefType } from './refTypes';
791
524
  export type ConstrItem = Record<string, any>;
792
525
  export type ConstrValue<T = any> = { value?: T; };
793
526
  export type ConstrComponent = Record<string, any>;
@@ -802,54 +535,22 @@ export type ConstrClassList = Record<string, ConstrClass>;
802
535
  export type ConstrClasses = { main: ConstrClass; } & ConstrClassList;
803
536
  export type ConstrStylesItem = string | null;
804
537
  export type ConstrStyles = Record<string, ConstrStylesItem> | ConstrStyles[];
805
- export type ConstrOptions<COMP extends ConstrComponent, EMITS extends ConstrItem, P extends ConstrItem> = {
806
- components?: COMP;
807
- compMod?: ConstrComponentMod<P>;
808
- emits?: ConstrEmit<EMITS>;
809
- classes?: RefType<ConstrClasses>;
810
- styles?: RefType<ConstrStyles>;
811
- };
812
- export type ConstrSetup<E extends Element, CLASSES extends ConstrClasses, SETUP extends ConstrItem> = {
813
- name: string;
814
- element: Ref<E | undefined>;
815
- classes: RefType<CLASSES>;
816
- styles: RefType<ConstrStyles>;
817
- } & SETUP;
538
+ export type ConstrOptions<COMP extends ConstrComponent, EMITS extends ConstrItem, P extends ConstrItem> = { components?: COMP; compMod?: ConstrComponentMod<P>; emits?: ConstrEmit<EMITS>; classes?: RefType<ConstrClasses>; styles?: RefType<ConstrStyles>; };
539
+ export type ConstrSetup<E extends Element, CLASSES extends ConstrClasses, SETUP extends ConstrItem> = { name: string; element: Ref<E | undefined>; classes: RefType<CLASSES>; styles: RefType<ConstrStyles>; } & SETUP;
818
540
  export type ConstrRegistration = { flag?: boolean; translate?: Record<string, string>; };
819
- export type ConstrBind<T> = T & Record<string, any> & {
820
- key?: string;
821
- class?: ConstrClass;
822
- style?: ConstrStyles;
823
- };
824
- export type ConstrPropItemOptions<T = any> = {
825
- type?: PropType<T>;
826
- required?: boolean;
827
- default?: any;
828
- validator?(value: any, props: any): boolean;
829
- };
541
+ export type ConstrBind<T> = T & Record<string, any> & { key?: string; class?: ConstrClass; style?: ConstrStyles; };
542
+ export type ConstrPropItemOptions<T = any> = { type?: PropType<T>; required?: boolean; default?: any; validator?(value: any, props: any): boolean; };
830
543
  export type ConstrPropItem<T = any> = ConstrPropItemOptions<T> | PropType<T>;
831
544
  export type ConstrProps<P = Record<string, any>> = { [K in keyof P]: ConstrPropItem<P[K]>; };
832
545
  export type ConstrHrefProps = { href?: string; };
833
546
 
834
547
  // File: src/types/listTypes.d.ts
835
- import { NumberOrString, NumberOrStringOrBoolean } from '@dxtmisha/functional-basic';
836
- import { ConstrBind } from './constructorTypes';
837
548
  export type ListType = 'item' | 'space' | 'line' | 'subtitle' | 'html' | 'menu' | 'menu-group' | 'group';
838
549
  export type ListDataBasic = { label?: NumberOrString; value?: any; search?: string; };
839
- export type ListDataItem<Item extends ListDataBasic = ListDataBasic> = ConstrBind<Item & {
840
- parent?: string;
841
- type: ListType;
842
- index: string;
843
- disabled?: boolean;
844
- }>;
550
+ export type ListDataItem<Item extends ListDataBasic = ListDataBasic> = ConstrBind<Item & { parent?: string; type: ListType; index: string; disabled?: boolean; }>;
845
551
  export type ListList<Item extends ListDataBasic = ListDataBasic> = ListDataItem<Item>[];
846
552
  export type ListRecord<Item extends ListDataBasic = ListDataBasic> = ListList<Item> | Record<string, any>;
847
- export type ListDataFullItem<Item extends ListDataBasic = ListDataBasic> = ListDataItem<Item> & {
848
- focus: boolean;
849
- highlight?: string;
850
- selected: boolean;
851
- disabled?: boolean;
852
- };
553
+ export type ListDataFullItem<Item extends ListDataBasic = ListDataBasic> = ListDataItem<Item> & { focus: boolean; highlight?: string; selected: boolean; disabled?: boolean; };
853
554
  export type ListDataFull<Item extends ListDataBasic = ListDataBasic> = ListDataFullItem<Item>[];
854
555
  export type ListListInputItem<Item extends ListDataBasic = ListDataBasic> = ConstrBind<Item>;
855
556
  export type ListListInput<Item extends ListDataBasic = ListDataBasic> = ListListInputItem<Item>[] | string[] | Record<string, ListListInputItem<Item>> | Record<string, string>;
@@ -859,7 +560,6 @@ export type ListName = string | number | undefined;
859
560
  export type ListNames = ListName[];
860
561
 
861
562
  // File: src/types/refTypes.d.ts
862
- import { ComputedRef, Ref, VNode, VNodeArrayChildren } from 'vue';
863
563
  export type RefType<T> = ComputedRef<T> | Ref<T>;
864
564
  export type RefUndefined<T> = RefType<T | undefined>;
865
565
  export type RefOrNormal<T> = RefType<T> | T;
@@ -868,7 +568,5 @@ export type RawChildren = string | number | boolean | VNode | VNodeArrayChildren
868
568
  export type RawSlots = { [name: string]: unknown; $stable?: boolean; };
869
569
 
870
570
  // File: src/types/searchTypes.d.ts
871
- import { RefOrNormal } from './refTypes';
872
- import { SearchItem, SearchListValue } from '@dxtmisha/functional-basic';
873
571
  export type SearchListValueRef<T extends SearchItem> = RefOrNormal<SearchListValue<T>>;
874
572
  export type SearchListInput<T extends SearchItem> = SearchListValueRef<T> | (() => SearchListValueRef<T>);
package/dist/library.js CHANGED
@@ -371,6 +371,9 @@ var Oe = class {
371
371
  static set(e) {
372
372
  u.set(e, !0), this.get().value = u.getItem();
373
373
  }
374
+ static setValueDefault(e) {
375
+ u.setValueDefault(e), this.get().value = u.getItem();
376
+ }
374
377
  };
375
378
  J = Y, H(Y, "country", I(() => J.get().value.country)), H(Y, "language", I(() => J.get().value.language)), H(Y, "standard", I(() => J.get().value.standard)), H(Y, "firstDay", I(() => J.get().value.firstDay));
376
379
  //#endregion
@@ -1306,7 +1309,7 @@ function Dt(e, t) {
1306
1309
  //#endregion
1307
1310
  //#region src/functions/dxtFunctionalPlugin.ts
1308
1311
  var Ot = { install(t, n = {}) {
1309
- if (n.api && e.setConfig(n.api), n.translate && b.setConfig(n.translate), n.icons && m.setConfig(n.icons), n.metaSuffix && _t().setSuffix(n.metaSuffix), n.router) X.set(n.router);
1312
+ if (n.api && e.setConfig(n.api), n.translate && b.setConfig(n.translate), n.location && Y.setValueDefault(n.location), n.icons && m.setConfig(n.icons), n.metaSuffix && _t().setSuffix(n.metaSuffix), n.router) X.set(n.router);
1310
1313
  else {
1311
1314
  let e = t.config.globalProperties.$router;
1312
1315
  e && X.set(e);
@@ -55,4 +55,11 @@ export declare class GeoRef {
55
55
  * код страны, полный вид язык-страна или один из них
56
56
  */
57
57
  static set(code: string): void;
58
+ /**
59
+ * Sets the default value for the country code.
60
+ *
61
+ * Устанавливает значение по умолчанию для кода страны.
62
+ * @param code default code value / значение кода по умолчанию
63
+ */
64
+ static setValueDefault(code?: string | (() => string)): void;
58
65
  }
@@ -16,6 +16,11 @@ export interface FunctionalPluginOptions {
16
16
  * Конфигурация для сервиса переводов
17
17
  */
18
18
  translate?: TranslateConfig;
19
+ /**
20
+ * Default geographical location or language code /
21
+ * Код географического местоположения или языка по умолчанию
22
+ */
23
+ location?: string | (() => string);
19
24
  /**
20
25
  * Suffix to be appended to all page titles /
21
26
  * Суффикс, который будет добавляться ко всем заголовкам страниц
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@dxtmisha/functional",
3
3
  "private": false,
4
- "version": "1.13.2",
4
+ "version": "1.13.4",
5
5
  "type": "module",
6
6
  "description": "A comprehensive library of utilities, base classes, and Vue 3 composables for reactive web development. Extends @dxtmisha/functional-basic with Composition API.",
7
7
  "keywords": [