@dxtmisha/functional 1.13.5 → 1.14.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/CHANGELOG.md +18 -0
- package/ai-description.md +16 -0
- package/ai-doc.md +226 -0
- package/{ai-types.txt → ai-types.md} +87 -163
- package/dist/library.js +178 -156
- package/dist/src/classes/ref/GeoRef.d.ts +21 -0
- package/dist/src/composables/ref/useQueryRef.d.ts +9 -0
- package/dist/src/library.d.ts +1 -0
- package/package.json +4 -5
- package/ai-description.txt +0 -18
- package/ai-doc.ru.txt +0 -45
- package/ai-doc.txt +0 -45
package/CHANGELOG.md
CHANGED
|
@@ -2,8 +2,26 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
|
|
5
|
+
## [1.14.0] - 2026-06-22
|
|
6
|
+
|
|
7
|
+
### Added
|
|
8
|
+
- **useQueryRef**: Introduced a new Vue 3 reactive composable to manage URL query/GET parameters reactively, mimicking `useHashRef` behavior.
|
|
9
|
+
- **useQueryRef**: Added `useQueryRef.test.ts` unit test suite to validate parameter retrieval, reactive updates, and event callbacks.
|
|
10
|
+
|
|
11
|
+
### Fixed
|
|
12
|
+
- **GeoRef**: Updated `GeoRef.test.ts` assertions for the `'en-VN'` locale to expect country `'VN'` and language `'vi'` to align with the country-first localization resolution updates.
|
|
13
|
+
|
|
14
|
+
## [1.13.7] - 2026-06-19
|
|
15
|
+
|
|
16
|
+
### Added
|
|
17
|
+
- **GeoRef**: Added static reactive `getLocation()`, `getLocationCountry()`, and `getLocationLanguage()` methods returning isolated `ComputedRef<string>` representations of location components.
|
|
18
|
+
|
|
19
|
+
### Fixed
|
|
20
|
+
- **Tests**: Adjusted test assertions in `GeoRef.test.ts` for `'en-VN'` to expect country `'VN'` and standard `'en-VN'` under the country-first matching priority.
|
|
21
|
+
|
|
5
22
|
## [1.13.5] - 2026-06-17
|
|
6
23
|
|
|
24
|
+
|
|
7
25
|
### Changed / Improved
|
|
8
26
|
- **GeoRef**: Refactored static getters (`getCountry`, `getLanguage`, `getStandard`, `getFirstDay`) to use request-isolated computed references via `ServerStorage.get`. This isolates their reactive state per request, resolving potential cross-request state pollution during SSR.
|
|
9
27
|
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
Core Purpose: Provides a structured, reactive framework for Vue 3 component design and API orchestration. It simplifies complex UI state management, internationalization, and asynchronous API interactions through specialized classes and composables.
|
|
2
|
+
|
|
3
|
+
Key Expositions:
|
|
4
|
+
- Design Construction: DesignAbstract, DesignAsyncAbstract, and DesignComponents for building complex component structures with lifecycle hooks and automated change tracking.
|
|
5
|
+
- API Orchestration: useApiRef, useApiManagementRef (and Async variants) for handling GET/POST/PUT/DELETE requests with built-in SSR support, validation (contract-based), reactivity, and skeleton states.
|
|
6
|
+
- Reactive Utilities: ListDataRef (list management/selection/navigation), DatetimeRef (reactive date manipulation), and GeoRef/GeoIntlRef (geo-data and internationalization).
|
|
7
|
+
- Global State: executeUse (Global/Provide/Local patterns) for managing singletons, useMeta (global SEO management), and various storage/browser-tab sync hooks (useCookieRef, useSessionRef, useBroadcastValueRef).
|
|
8
|
+
- Render Utilities: Helper functions for VNode rendering, class/style binding (getBind, toBind), and reactive property unwrapping (getRef, executeFunctionRef).
|
|
9
|
+
|
|
10
|
+
Triggers for Studying ai-types.md:
|
|
11
|
+
- When encountering errors or ambiguity regarding Type constraints for API request/response contracts (`ApiDataValidation`, `ApiErrorStorageList`).
|
|
12
|
+
- When defining complex component Props or custom UI structures that require specific type inference for classes, styles, or slots.
|
|
13
|
+
- When implementing data lists (`ListDataRef`) or search logic that depends on strict structural compliance defined by `ListTypes` or `SearchTypes`.
|
|
14
|
+
- When integrating the `dxtFunctionalPlugin` or configuring custom API/Translate instances.
|
|
15
|
+
|
|
16
|
+
Integration Context: Built on top of Vue 3 and its reactivity system (Refs, Computed, EffectScope). It acts as a bridge between the `@dxtmisha/functional-basic` library and Vue, specifically handling the transformation of raw functional logic into Vue-compatible reactive objects, composables, and lifecycle-aware services.
|
package/ai-doc.md
ADDED
|
@@ -0,0 +1,226 @@
|
|
|
1
|
+
This is the main functional library for the Vue environment (@dxtmisha/functional). It contains Vue-specific utilities, composables, and reactive classes.
|
|
2
|
+
|
|
3
|
+
USAGE RULES:
|
|
4
|
+
1. When developing in Vue, always use this library for functionality, logic, and composables instead of `@dxtmisha/functional-basic` whenever possible.
|
|
5
|
+
2. It wraps basic non-reactive logic into Vue's reactivity system. If the required function or composable exists here, it has absolute priority.
|
|
6
|
+
3. Import utilities from `@dxtmisha/functional` for reactive UI behavior, composables, and state management.
|
|
7
|
+
|
|
8
|
+
WORKING WITH API AND STATE (useApi / executeUse):
|
|
9
|
+
A set of composables is provided for network requests: `useApiGet`, `useApiPost`, `useApiPut`, `useApiDelete`, `useApiRequest`, `useApiRef`, `useApiAsyncRef`, `useApiManagementRef`, `useApiManagementAsyncRef`.
|
|
10
|
+
Strictly follow these rules for their application:
|
|
11
|
+
|
|
12
|
+
1. DO NOT call these composables directly in the Vue components (SFC).
|
|
13
|
+
2. Move all API configurations and `useApi*` calls into SEPARATE FILES (services/stores).
|
|
14
|
+
3. Wrap the API configurations inside the `executeUse` factory (specifically: `executeUseGlobal`, `executeUseProvide`, or `executeUseLocal` from `src/functions/executeUse.ts`). This guarantees the creation of managed singletons (single access point) and prevents duplicated requests and reactive states.
|
|
15
|
+
4. Perform any additional request processing (e.g., data mapping, preparing structures for skeletons before loading a form) in the same file, inside the `executeUse` callback, and return a fully prepared set of data and methods.
|
|
16
|
+
*Example of correct usage:*
|
|
17
|
+
```ts
|
|
18
|
+
import { executeUseGlobal } from '@dxtmisha/functional';
|
|
19
|
+
import { useApiManagementRef } from '@dxtmisha/functional';
|
|
20
|
+
|
|
21
|
+
export const useUserManagement = executeUseGlobal(() => {
|
|
22
|
+
return useApiManagementRef(
|
|
23
|
+
{ path: '/api/users' }, // GET setup
|
|
24
|
+
{ date: (v) => new Date(v).toLocaleString() }, // Formatters
|
|
25
|
+
{ columns: ['name', 'email'] }, // Search
|
|
26
|
+
{ path: '/api/users' }, // POST
|
|
27
|
+
{ path: (o) => `/api/users/${o.id}` }, // PUT
|
|
28
|
+
{ path: (o) => `/api/users/${o.id}` } // DELETE
|
|
29
|
+
);
|
|
30
|
+
// Logic for skeletons, additional formatting, etc., should be added here,
|
|
31
|
+
// and then return the extended object.
|
|
32
|
+
});
|
|
33
|
+
```
|
|
34
|
+
5. Within the Vue component itself, simply import and call your custom singleton composable: `const { list, loading, sendPost } = useUserManagement();`
|
|
35
|
+
|
|
36
|
+
CHOOSING THE executeUse STRATEGY:
|
|
37
|
+
1. `executeUseLocal` (PREFERRED):
|
|
38
|
+
- When to use: For most API requests and services.
|
|
39
|
+
- Key Features: Works "lazily" (lazy initialization) — initializes only when first called. The instance persists until the end of the session. This prevents overloading the application start with unnecessary requests.
|
|
40
|
+
2. `executeUseGlobal`:
|
|
41
|
+
- When to use: When data or a service must be loaded/initialized IMMEDIATELY at application start (e.g., critical settings, SDKs).
|
|
42
|
+
- Key Features: Creates a single instance for the entire application. All global singletons are forcibly initialized via `executeUseGlobalInit()`.
|
|
43
|
+
3. `executeUseProvide`:
|
|
44
|
+
- When to use: For state shared between a parent and a group of child components (e.g., tabs, complex forms with sub-components).
|
|
45
|
+
- Key Features: Uses provide/inject. The first component in the tree that calls the hook becomes the "provider", others become consumers.
|
|
46
|
+
|
|
47
|
+
=============================================================================
|
|
48
|
+
DEVELOPER GUIDE: USING `@dxtmisha/functional` AS A LIBRARY
|
|
49
|
+
=============================================================================
|
|
50
|
+
|
|
51
|
+
This section contains instructions and code guidelines for AI models on how to import and use the Vue-specific reactive classes, composables, and utility functions provided by this library in Vue 3 / Nuxt applications.
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
|
|
55
|
+
### 1. Reactive Storage & State Composables
|
|
56
|
+
|
|
57
|
+
These composables bind browser storages reactively to Vue `Ref` objects, keeping them in sync.
|
|
58
|
+
|
|
59
|
+
#### `useStorageRef` (localStorage)
|
|
60
|
+
Reactively binds a key from `localStorage`.
|
|
61
|
+
```typescript
|
|
62
|
+
import { useStorageRef } from '@dxtmisha/functional';
|
|
63
|
+
|
|
64
|
+
// Bind to key with optional initial default value
|
|
65
|
+
const theme = useStorageRef<'light' | 'dark'>('theme_key', 'light');
|
|
66
|
+
|
|
67
|
+
// Setting the value triggers an immediate update to localStorage reactively
|
|
68
|
+
theme.value = 'dark';
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
#### `useSessionRef` (sessionStorage) & `useCookieRef` (Cookies)
|
|
72
|
+
```typescript
|
|
73
|
+
import { useSessionRef, useCookieRef } from '@dxtmisha/functional';
|
|
74
|
+
|
|
75
|
+
// sessionStorage
|
|
76
|
+
const step = useSessionRef<number>('form_step', 1);
|
|
77
|
+
|
|
78
|
+
// CookieStorage
|
|
79
|
+
const token = useCookieRef<string>('auth_token', '', { secure: true });
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
#### `useBroadcastValueRef` (Cross-Tab Synchronization)
|
|
83
|
+
Synchronizes a state value reactively across multiple browser tabs under the same origin.
|
|
84
|
+
```typescript
|
|
85
|
+
import { useBroadcastValueRef } from '@dxtmisha/functional';
|
|
86
|
+
|
|
87
|
+
// Synchronizes the value of the ref across tabs using BroadcastChannel
|
|
88
|
+
const syncState = useBroadcastValueRef<string>('active_channel', 'idle');
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
#### `useHashRef` (URL Hash)
|
|
92
|
+
Reactively binds Vue state to the URL hash parameters.
|
|
93
|
+
```typescript
|
|
94
|
+
import { useHashRef } from '@dxtmisha/functional';
|
|
95
|
+
|
|
96
|
+
const hashPage = useHashRef<string>('page', 'home');
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
---
|
|
100
|
+
|
|
101
|
+
### 2. Reactive Geolocation & Internationalization (`GeoRef`, `GeoIntlRef`, `GeoFlagRef`, `useTranslateRef`)
|
|
102
|
+
|
|
103
|
+
Provides reactive integrations for internationalization APIs.
|
|
104
|
+
|
|
105
|
+
#### `GeoRef` & `GeoIntlRef`
|
|
106
|
+
```typescript
|
|
107
|
+
import { GeoRef, useGeoIntlRef } from '@dxtmisha/functional';
|
|
108
|
+
|
|
109
|
+
// Reactive tracking of user location details
|
|
110
|
+
const currentCountry = GeoRef.getCountry(); // ComputedRef<string>
|
|
111
|
+
|
|
112
|
+
// Reactive i18n formatter hook
|
|
113
|
+
const intl = useGeoIntlRef();
|
|
114
|
+
const formattedPrice = intl.currency(150, 'EUR'); // ComputedRef<string>
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
#### `useTranslateRef`
|
|
118
|
+
Reactively loads and gets translation tokens.
|
|
119
|
+
```typescript
|
|
120
|
+
import { useTranslateRef } from '@dxtmisha/functional';
|
|
121
|
+
|
|
122
|
+
const translations = useTranslateRef(['global.save', 'global.cancel']);
|
|
123
|
+
// returns: ShallowRef<Record<string, string>> containing loaded translations
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
---
|
|
127
|
+
|
|
128
|
+
### 3. SEO & Layout Utilities
|
|
129
|
+
|
|
130
|
+
#### `useMeta`
|
|
131
|
+
Manages page metadata reactively. Calling setters will update document headers and tags reactively.
|
|
132
|
+
```typescript
|
|
133
|
+
import { useMeta } from '@dxtmisha/functional';
|
|
134
|
+
|
|
135
|
+
const metaManager = useMeta();
|
|
136
|
+
metaManager.setTitle('My Product Page');
|
|
137
|
+
metaManager.setDescription('Product details and configurations.');
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
#### `ScrollbarWidthRef`
|
|
141
|
+
Tracks the scrollbar width reactively to solve layout shift issues.
|
|
142
|
+
```typescript
|
|
143
|
+
import { ScrollbarWidthRef } from '@dxtmisha/functional';
|
|
144
|
+
|
|
145
|
+
const scrollbar = new ScrollbarWidthRef();
|
|
146
|
+
const width = scrollbar.width; // Ref<number>
|
|
147
|
+
const hasScroll = scrollbar.is; // ComputedRef<boolean>
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
---
|
|
151
|
+
|
|
152
|
+
### 4. Advanced Reactivity Helpers
|
|
153
|
+
|
|
154
|
+
#### `computedAsync`
|
|
155
|
+
Creates a computed property that resolves its value asynchronously. Useful for async tasks inside computed getters.
|
|
156
|
+
```typescript
|
|
157
|
+
import { computedAsync } from '@dxtmisha/functional';
|
|
158
|
+
|
|
159
|
+
// Performs asynchronous data lookup and reactively returns the result
|
|
160
|
+
const asyncData = computedAsync(async () => {
|
|
161
|
+
return await fetchSomeData(activeId.value);
|
|
162
|
+
}, 'initial_loading_value');
|
|
163
|
+
```
|
|
164
|
+
|
|
165
|
+
#### `computedEternity`
|
|
166
|
+
Computes an asynchronous value once and caches it indefinitely unless manually refreshed.
|
|
167
|
+
```typescript
|
|
168
|
+
import { computedEternity } from '@dxtmisha/functional';
|
|
169
|
+
|
|
170
|
+
const cachedData = computedEternity(async () => {
|
|
171
|
+
return await fetchStaticData();
|
|
172
|
+
}, 'loading_state');
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
---
|
|
176
|
+
|
|
177
|
+
### 5. List & Search Orchestration
|
|
178
|
+
|
|
179
|
+
#### `ListDataRef`
|
|
180
|
+
A powerful reactive state orchestrator for managing lists, groups, items, pagination, highlight paths, and selections.
|
|
181
|
+
```typescript
|
|
182
|
+
import { ListDataRef } from '@dxtmisha/functional';
|
|
183
|
+
|
|
184
|
+
const items = ref([
|
|
185
|
+
{ value: 'id1', label: 'First Option' },
|
|
186
|
+
{ value: 'id2', label: 'Second Option' },
|
|
187
|
+
]);
|
|
188
|
+
const selectedId = ref('id1');
|
|
189
|
+
|
|
190
|
+
const listData = new ListDataRef(items, selectedId);
|
|
191
|
+
const isSelected = listData.isSelected; // ComputedRef<boolean>
|
|
192
|
+
const nextItem = listData.getSelectedNext(); // returns next select item
|
|
193
|
+
```
|
|
194
|
+
|
|
195
|
+
#### `useSearchRef`
|
|
196
|
+
Combines a source list, target fields, search query, and options to reactively search a list with built-in delay and highlight support.
|
|
197
|
+
```typescript
|
|
198
|
+
import { useSearchRef } from '@dxtmisha/functional';
|
|
199
|
+
|
|
200
|
+
const query = ref('second');
|
|
201
|
+
const { listSearch, loading, length } = useSearchRef(items, ['label'], query);
|
|
202
|
+
```
|
|
203
|
+
|
|
204
|
+
---
|
|
205
|
+
|
|
206
|
+
### 6. DOM & Lazy Rendering
|
|
207
|
+
|
|
208
|
+
#### `EventRef`
|
|
209
|
+
Reactive wrapper for DOM events. Starts and stops event binding cleanly inside Vue component lifecycles (runs setup and teardown hooks automatically).
|
|
210
|
+
```typescript
|
|
211
|
+
import { EventRef } from '@dxtmisha/functional';
|
|
212
|
+
|
|
213
|
+
// Listens reactively; auto-starts on setup and auto-stops on unmounted
|
|
214
|
+
const keyListener = new EventRef(window, window, 'keydown', (event) => {
|
|
215
|
+
console.log('Key pressed', event.key);
|
|
216
|
+
});
|
|
217
|
+
```
|
|
218
|
+
|
|
219
|
+
#### `useLazyRef`
|
|
220
|
+
Reactive manager utilizing `IntersectionObserver` to defer rendering of off-screen components.
|
|
221
|
+
```typescript
|
|
222
|
+
import { useLazyRef } from '@dxtmisha/functional';
|
|
223
|
+
|
|
224
|
+
const lazyManager = useLazyRef();
|
|
225
|
+
const isVisible = lazyManager.addLazyItem(elementRef); // ShallowRef<boolean>
|
|
226
|
+
```
|
|
@@ -16,10 +16,6 @@ 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>;
|
|
23
19
|
constructor(props: T, callback?: ((event: C) => void) | undefined, changed?: string[]);
|
|
24
20
|
make(compelled?: boolean): this;
|
|
25
21
|
makeCallback(compelled?: boolean): void;
|
|
@@ -35,8 +31,6 @@ export declare abstract class DesignAsyncAbstract<T extends Record<string, any>,
|
|
|
35
31
|
|
|
36
32
|
// File: src/classes/design/DesignChanged.d.ts
|
|
37
33
|
export declare class DesignChanged<T extends Record<string, any>> {
|
|
38
|
-
protected readonly props: T;
|
|
39
|
-
protected readonly watch: string[];
|
|
40
34
|
constructor(props: T, watch?: string[]);
|
|
41
35
|
is(name: string | string[]): boolean;
|
|
42
36
|
isChanged(): boolean;
|
|
@@ -49,9 +43,6 @@ export declare class DesignComp<COMP extends ConstrComponent, P extends ConstrIt
|
|
|
49
43
|
|
|
50
44
|
// File: src/classes/design/DesignComponents.d.ts
|
|
51
45
|
export declare class DesignComponents<COMP extends ConstrComponent, P extends ConstrItem> {
|
|
52
|
-
protected readonly components: COMP;
|
|
53
|
-
protected readonly modification?: ConstrComponentMod<P> | undefined;
|
|
54
|
-
protected caching: Record<string, ComputedRef<any>>;
|
|
55
46
|
constructor(components?: COMP, modification?: ConstrComponentMod<P> | undefined);
|
|
56
47
|
is<K extends keyof COMP>(name: K): name is K;
|
|
57
48
|
get<K extends keyof COMP>(name: K): COMP[K];
|
|
@@ -63,20 +54,6 @@ export declare class DesignComponents<COMP extends ConstrComponent, P extends Co
|
|
|
63
54
|
|
|
64
55
|
// File: src/classes/design/DesignConstructorAbstract.d.ts
|
|
65
56
|
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> {
|
|
66
|
-
protected readonly props: Readonly<P>;
|
|
67
|
-
protected readonly options?: ConstrOptions<COMP, EMITS, P> | undefined;
|
|
68
|
-
protected readonly name: string[];
|
|
69
|
-
protected readonly element: Ref<E | undefined, E | undefined>;
|
|
70
|
-
protected readonly refs: ToRefs<P>;
|
|
71
|
-
protected readonly components: DesignComponents<COMP, P>;
|
|
72
|
-
protected readonly emits?: ConstrEmit<EMITS>;
|
|
73
|
-
protected readonly classes?: ComputedRef<CLASSES>;
|
|
74
|
-
protected classesSub?: ComputedRef<Partial<CLASSES>>;
|
|
75
|
-
protected readonly styles?: ComputedRef<ConstrStyles>;
|
|
76
|
-
protected stylesSub?: ComputedRef<ConstrStyles>;
|
|
77
|
-
protected attrs?: ConstrItem;
|
|
78
|
-
protected slots?: SLOTS;
|
|
79
|
-
protected dataExpose?: EXPOSE;
|
|
80
57
|
protected constructor(name: string, props: Readonly<P>, options?: ConstrOptions<COMP, EMITS, P> | undefined);
|
|
81
58
|
protected init(): this;
|
|
82
59
|
getName(): string;
|
|
@@ -91,24 +68,10 @@ export declare abstract class DesignConstructorAbstract<E extends Element, COMP
|
|
|
91
68
|
protected abstract initClasses(): Partial<CLASSES>;
|
|
92
69
|
protected abstract initStyles(): ConstrStyles;
|
|
93
70
|
protected abstract initRender(): VNode | (VNode | any)[] | undefined;
|
|
94
|
-
protected initSlot<K extends keyof SLOTS>(name: K, children?: any[], props?: ConstrItem): VNode | undefined;
|
|
95
|
-
protected toClass(classes?: ConstrClass): ConstrClassObject;
|
|
96
|
-
protected toClassName<T extends ConstrItem>(classes?: ConstrItem): T;
|
|
97
71
|
}
|
|
98
72
|
|
|
99
73
|
// File: src/classes/ref/DatetimeRef.d.ts
|
|
100
74
|
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>;
|
|
112
75
|
constructor(date: RefOrNormal<NumberOrStringOrDate>, type?: RefOrNormal<GeoDate>, code?: RefOrNormal<string>);
|
|
113
76
|
getItem(): Ref<NumberOrStringOrDate>;
|
|
114
77
|
getDate(): Ref<Date>;
|
|
@@ -138,7 +101,6 @@ export declare class EventRef<E extends ElementOrWindow, O extends Event, D exte
|
|
|
138
101
|
|
|
139
102
|
// File: src/classes/ref/GeoFlagRef.d.ts
|
|
140
103
|
export declare class GeoFlagRef {
|
|
141
|
-
protected flag: ComputedRef<GeoFlag>;
|
|
142
104
|
constructor(code?: RefOrNormal<string | undefined>);
|
|
143
105
|
getCode(): string;
|
|
144
106
|
get(code?: RefOrNormal<string>): ComputedRef<GeoFlagItem | undefined>;
|
|
@@ -181,25 +143,15 @@ export declare class GeoRef {
|
|
|
181
143
|
static getLanguage(): ComputedRef<string>;
|
|
182
144
|
static getStandard(): ComputedRef<string>;
|
|
183
145
|
static getFirstDay(): ComputedRef<string>;
|
|
146
|
+
static getLocation(): ComputedRef<string>;
|
|
147
|
+
static getLocationCountry(): ComputedRef<string>;
|
|
148
|
+
static getLocationLanguage(): ComputedRef<string>;
|
|
184
149
|
static set(code: string): void;
|
|
185
150
|
static setValueDefault(code?: string | (() => string)): void;
|
|
186
151
|
}
|
|
187
152
|
|
|
188
153
|
// File: src/classes/ref/ListDataRef.d.ts
|
|
189
154
|
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>;
|
|
203
155
|
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);
|
|
204
156
|
readonly data: ComputedRef<ListList>;
|
|
205
157
|
readonly liteData: ComputedRef<ListList>;
|
|
@@ -267,129 +219,34 @@ export declare function useApiAsyncRef<R, T = R>(path?: RefOrNormal<string | und
|
|
|
267
219
|
|
|
268
220
|
// File: src/composables/ref/useApiDelete.d.ts
|
|
269
221
|
export interface UseApiDeleteSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {}
|
|
270
|
-
export declare function useApiDelete<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiDeleteSetup<T, Request, Return>): {
|
|
271
|
-
loading: Ref<boolean, boolean>;
|
|
272
|
-
send(request?: Request | undefined): Promise<Return | undefined>;
|
|
273
|
-
};
|
|
222
|
+
export declare function useApiDelete<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiDeleteSetup<T, Request, Return>): { loading: Ref<boolean, boolean>; send(request?: Request | undefined): Promise<Return | undefined>; };
|
|
274
223
|
|
|
275
224
|
// File: src/composables/ref/useApiGet.d.ts
|
|
276
225
|
export interface UseApiGetSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {}
|
|
277
|
-
export declare function useApiGet<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiGetSetup<T, Request, Return>): {
|
|
278
|
-
loading: Ref<boolean, boolean>;
|
|
279
|
-
send(request?: Request | undefined): Promise<Return | undefined>;
|
|
280
|
-
};
|
|
226
|
+
export declare function useApiGet<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiGetSetup<T, Request, Return>): { loading: Ref<boolean, boolean>; send(request?: Request | undefined): Promise<Return | undefined>; };
|
|
281
227
|
|
|
282
228
|
// File: src/composables/ref/useApiManagementAsyncRef.d.ts
|
|
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): {
|
|
284
|
-
isValid: ComputedRef<boolean>;
|
|
285
|
-
isResponseContractValid: ComputedRef<boolean>;
|
|
286
|
-
responseValidationResult: ComputedRef< ApiDataValidation | undefined>;
|
|
287
|
-
list: ComputedRef<SearchFormatList<ItemFormatters, Columns>>;
|
|
288
|
-
readonly data: ComputedRef< ApiData<Return> | undefined>;
|
|
289
|
-
errorItem: ComputedRef< ApiErrorItem | undefined>;
|
|
290
|
-
readonly length: ComputedRef<number>;
|
|
291
|
-
lengthData: ComputedRef<number>;
|
|
292
|
-
starting: ComputedRef<boolean>;
|
|
293
|
-
reading: Ref<boolean, boolean>;
|
|
294
|
-
loading: Ref<boolean, boolean>;
|
|
295
|
-
loadingSearch: Ref<boolean, boolean> | undefined;
|
|
296
|
-
loadingPost: Ref<boolean, boolean> | undefined;
|
|
297
|
-
loadingPut: Ref<boolean, boolean> | undefined;
|
|
298
|
-
loadingDelete: Ref<boolean, boolean> | undefined;
|
|
299
|
-
isSearch: ComputedRef<boolean> | undefined;
|
|
300
|
-
search: Ref<string>;
|
|
301
|
-
init: () => void;
|
|
302
|
-
initSsr: () => void;
|
|
303
|
-
reset: () => Promise<void>;
|
|
304
|
-
abort: () => void;
|
|
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>;
|
|
308
|
-
};
|
|
229
|
+
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): { isValid: ComputedRef<boolean>; isResponseContractValid: ComputedRef<boolean>; responseValidationResult: ComputedRef< ApiDataValidation | undefined>; list: ComputedRef<SearchFormatList<ItemFormatters, Columns>>; readonly data: ComputedRef< ApiData<Return> | undefined>; errorItem: ComputedRef< ApiErrorItem | undefined>; readonly length: ComputedRef<number>; lengthData: ComputedRef<number>; starting: ComputedRef<boolean>; reading: Ref<boolean, boolean>; loading: Ref<boolean, boolean>; loadingSearch: Ref<boolean, boolean> | undefined; loadingPost: Ref<boolean, boolean> | undefined; loadingPut: Ref<boolean, boolean> | undefined; loadingDelete: Ref<boolean, boolean> | undefined; isSearch: ComputedRef<boolean> | undefined; search: Ref<string>; init: () => void; initSsr: () => void; reset: () => Promise<void>; abort: () => void; sendPost: (request?: ApiFetch["request"]) => Promise< ApiData<Post> | undefined>; sendPut: (request?: ApiFetch["request"]) => Promise< ApiData<Put> | undefined>; sendDelete: (request?: ApiFetch["request"]) => Promise< ApiData<Delete> | undefined>; };
|
|
309
230
|
|
|
310
231
|
// File: src/composables/ref/useApiManagementRef.d.ts
|
|
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): {
|
|
312
|
-
isValid: ComputedRef<boolean>;
|
|
313
|
-
isResponseContractValid: ComputedRef<boolean>;
|
|
314
|
-
responseValidationResult: ComputedRef< ApiDataValidation | undefined>;
|
|
315
|
-
list: ComputedRef<SearchFormatList<ItemFormatters, Columns>>;
|
|
316
|
-
readonly data: ComputedRef<ApiData<Return> | undefined>;
|
|
317
|
-
errorItem: ComputedRef< ApiErrorItem | undefined>;
|
|
318
|
-
readonly length: ComputedRef<number>;
|
|
319
|
-
lengthData: ComputedRef<number>;
|
|
320
|
-
starting: ComputedRef<boolean>;
|
|
321
|
-
reading: Ref<boolean, boolean>;
|
|
322
|
-
loading: Ref<boolean, boolean>;
|
|
323
|
-
loadingSearch: Ref<boolean, boolean> | undefined;
|
|
324
|
-
loadingPost: Ref<boolean, boolean> | undefined;
|
|
325
|
-
loadingPut: Ref<boolean, boolean> | undefined;
|
|
326
|
-
loadingDelete: Ref<boolean, boolean> | undefined;
|
|
327
|
-
isSearch: ComputedRef<boolean> | undefined;
|
|
328
|
-
search: Ref<string>;
|
|
329
|
-
init: () => void;
|
|
330
|
-
initSsr: () => void;
|
|
331
|
-
reset: () => Promise<void>;
|
|
332
|
-
abort: () => void;
|
|
333
|
-
sendPost: (request?: ApiFetch["request"]) => Promise<ApiData<Post> | undefined>;
|
|
334
|
-
sendPut: (request?: ApiFetch["request"]) => Promise<ApiData<Put> | undefined>;
|
|
335
|
-
sendDelete: (request?: ApiFetch["request"]) => Promise<ApiData<Delete> | undefined>;
|
|
336
|
-
};
|
|
232
|
+
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): { isValid: ComputedRef<boolean>; isResponseContractValid: ComputedRef<boolean>; responseValidationResult: ComputedRef< ApiDataValidation | undefined>; list: ComputedRef<SearchFormatList<ItemFormatters, Columns>>; readonly data: ComputedRef<ApiData<Return> | undefined>; errorItem: ComputedRef< ApiErrorItem | undefined>; readonly length: ComputedRef<number>; lengthData: ComputedRef<number>; starting: ComputedRef<boolean>; reading: Ref<boolean, boolean>; loading: Ref<boolean, boolean>; loadingSearch: Ref<boolean, boolean> | undefined; loadingPost: Ref<boolean, boolean> | undefined; loadingPut: Ref<boolean, boolean> | undefined; loadingDelete: Ref<boolean, boolean> | undefined; isSearch: ComputedRef<boolean> | undefined; search: Ref<string>; init: () => void; initSsr: () => void; reset: () => Promise<void>; abort: () => void; sendPost: (request?: ApiFetch["request"]) => Promise<ApiData<Post> | undefined>; sendPut: (request?: ApiFetch["request"]) => Promise<ApiData<Put> | undefined>; sendDelete: (request?: ApiFetch["request"]) => Promise<ApiData<Delete> | undefined>; };
|
|
337
233
|
|
|
338
234
|
// File: src/composables/ref/useApiPost.d.ts
|
|
339
235
|
export interface UseApiPostSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {}
|
|
340
|
-
export declare function useApiPost<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiPostSetup<T, Request, Return>): {
|
|
341
|
-
loading: Ref<boolean, boolean>;
|
|
342
|
-
send(request?: Request | undefined): Promise<Return | undefined>;
|
|
343
|
-
};
|
|
236
|
+
export declare function useApiPost<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiPostSetup<T, Request, Return>): { loading: Ref<boolean, boolean>; send(request?: Request | undefined): Promise<Return | undefined>; };
|
|
344
237
|
|
|
345
238
|
// File: src/composables/ref/useApiPut.d.ts
|
|
346
239
|
export interface UseApiPutSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> extends Omit<UseApiRequestSetup<T, Request, Return>, 'method'> {}
|
|
347
|
-
export declare function useApiPut<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiPutSetup<T, Request, Return>): {
|
|
348
|
-
loading: Ref<boolean, boolean>;
|
|
349
|
-
send(request?: Request | undefined): Promise<Return | undefined>;
|
|
350
|
-
};
|
|
240
|
+
export declare function useApiPut<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>(setup: UseApiPutSetup<T, Request, Return>): { loading: Ref<boolean, boolean>; send(request?: Request | undefined): Promise<Return | undefined>; };
|
|
351
241
|
|
|
352
242
|
// File: src/composables/ref/useApiRef.d.ts
|
|
353
|
-
export interface UseApiRef<R> {
|
|
354
|
-
data: ComputedRef<ApiData<R> | undefined>;
|
|
355
|
-
item: Ref<ApiData<R> | undefined>;
|
|
356
|
-
errorItem: ComputedRef<ApiErrorItem | undefined>;
|
|
357
|
-
isResponseContractValid: ComputedRef<boolean>;
|
|
358
|
-
responseValidationResult: ComputedRef<ApiDataValidation | undefined>;
|
|
359
|
-
length: ComputedRef<number>;
|
|
360
|
-
starting: ComputedRef<boolean>;
|
|
361
|
-
loading: Ref<boolean>;
|
|
362
|
-
reading: Ref<boolean>;
|
|
363
|
-
isStarting(): boolean;
|
|
364
|
-
isLoading(): boolean;
|
|
365
|
-
isReading(): boolean;
|
|
366
|
-
getItem(): ApiData<R> | undefined;
|
|
367
|
-
init(): void;
|
|
368
|
-
initSsr(): void;
|
|
369
|
-
reset(): Promise<void>;
|
|
370
|
-
stop(): void;
|
|
371
|
-
abort(): void;
|
|
372
|
-
}
|
|
243
|
+
export interface UseApiRef<R> { data: ComputedRef<ApiData<R> | undefined>; item: Ref<ApiData<R> | undefined>; errorItem: ComputedRef<ApiErrorItem | undefined>; isResponseContractValid: ComputedRef<boolean>; responseValidationResult: ComputedRef<ApiDataValidation | undefined>; length: ComputedRef<number>; starting: ComputedRef<boolean>; loading: Ref<boolean>; reading: Ref<boolean>; isStarting(): boolean; isLoading(): boolean; isReading(): boolean; getItem(): ApiData<R> | undefined; init(): void; initSsr(): void; reset(): Promise<void>; stop(): void; abort(): void; }
|
|
373
244
|
export declare function useApiRef<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>;
|
|
374
245
|
export declare const setApiRefGlobalConditions: (conditions: RefType<any>) => void;
|
|
375
246
|
|
|
376
247
|
// File: src/composables/ref/useApiRequest.d.ts
|
|
377
|
-
export interface UseApiRequestSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> {
|
|
378
|
-
|
|
379
|
-
method?: ApiMethodItem;
|
|
380
|
-
action?: (data: Return | undefined) => Promise<void> | void;
|
|
381
|
-
transformation?: (data: T) => Return;
|
|
382
|
-
validateRequestContract?: (data: Request) => ApiDataValidation & Return;
|
|
383
|
-
validateResponseContract?: (data: T) => ApiDataValidation & Return;
|
|
384
|
-
errorContract?: ApiErrorStorageList;
|
|
385
|
-
toData?: boolean;
|
|
386
|
-
options?: ApiOptions;
|
|
387
|
-
apiInstance?: ApiInstance;
|
|
388
|
-
}
|
|
389
|
-
export declare function useApiRequest<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>({ path, method, action, transformation, validateRequestContract, validateResponseContract, errorContract, toData, options, apiInstance }: UseApiRequestSetup<T, Request, Return>): {
|
|
390
|
-
loading: Ref<boolean, boolean>;
|
|
391
|
-
send(request?: Request): Promise<Return | undefined>;
|
|
392
|
-
};
|
|
248
|
+
export interface UseApiRequestSetup<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>> { path?: RefOrNormal<string | undefined>; method?: ApiMethodItem; 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; apiInstance?: ApiInstance; }
|
|
249
|
+
export declare function useApiRequest<T, Request extends ApiFetch['request'] = ApiFetch['request'], Return extends ApiData<T> = ApiData<T>>({ path, method, action, transformation, validateRequestContract, validateResponseContract, errorContract, toData, options, apiInstance }: UseApiRequestSetup<T, Request, Return>): { loading: Ref<boolean, boolean>; send(request?: Request): Promise<Return | undefined>; };
|
|
393
250
|
|
|
394
251
|
// File: src/composables/ref/useBroadcastValueRef.d.ts
|
|
395
252
|
export declare function useBroadcastValueRef<T>(name: string, defaultValue?: T | string | (() => (T | string))): Ref<T | string | undefined>;
|
|
@@ -398,10 +255,7 @@ export declare function useBroadcastValueRef<T>(name: string, defaultValue?: T |
|
|
|
398
255
|
export declare function useCookieRef<T>(name: string, defaultValue?: T | string | (() => (T | string)), options?: CookieOptions): Ref<T | string | undefined>;
|
|
399
256
|
|
|
400
257
|
// File: src/composables/ref/useFormattersRef.d.ts
|
|
401
|
-
export declare function useFormattersRef<Options extends FormattersOptionsList = FormattersOptionsList, List extends FormattersListProp = FormattersListProp>(list: RefType<List | undefined>, options: Options): {
|
|
402
|
-
listFormat: ComputedRef<FormattersReturn<List, Options>>;
|
|
403
|
-
length: ComputedRef<number>;
|
|
404
|
-
};
|
|
258
|
+
export declare function useFormattersRef<Options extends FormattersOptionsList = FormattersOptionsList, List extends FormattersListProp = FormattersListProp>(list: RefType<List | undefined>, options: Options): { listFormat: ComputedRef<FormattersReturn<List, Options>>; length: ComputedRef<number>; };
|
|
405
259
|
|
|
406
260
|
// File: src/composables/ref/useGeoIntlRef.d.ts
|
|
407
261
|
export declare function useGeoIntlRef(): GeoIntlRef;
|
|
@@ -422,7 +276,10 @@ export declare const useLazyRef: (options?: IntersectionObserverInit) => { inter
|
|
|
422
276
|
export declare function useLoadingRef(): ShallowRef<boolean, boolean>;
|
|
423
277
|
|
|
424
278
|
// File: src/composables/ref/useMeta.d.ts
|
|
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():
|
|
279
|
+
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(): any; destroyExecute?(): void; }>;
|
|
280
|
+
|
|
281
|
+
// File: src/composables/ref/useQueryRef.d.ts
|
|
282
|
+
export declare function useQueryRef<T>(name: string, defaultValue?: T | (() => T)): ShallowRef<T>;
|
|
426
283
|
|
|
427
284
|
// File: src/composables/ref/useRouterList.d.ts
|
|
428
285
|
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; };
|
|
@@ -466,9 +323,9 @@ export declare const dxtFunctionalPlugin: Plugin;
|
|
|
466
323
|
export declare enum ExecuteUseType { global = "global", provide = "provide", local = "local" }
|
|
467
324
|
export type ExecuteUseReturn<R> = Readonly<R & { init(): Readonly<R>; destroyExecute?(): void; }>;
|
|
468
325
|
export declare function executeUse<R, O extends any[], RI extends ExecuteUseReturn<R> = ExecuteUseReturn<R>>(callback: (...args: O) => R, type?: ExecuteUseType): ((...args: O) => RI) | (() => RI);
|
|
469
|
-
export declare function executeUseGlobal<R>(callback: () => R): (() => Readonly<
|
|
470
|
-
export declare function executeUseProvide<R, O extends any[]>(callback: (...args: O) => R): ((...args: O) => Readonly<
|
|
471
|
-
export declare function executeUseLocal<R, O extends any[]>(callback: (...args: O) => R): ((...args: O) => Readonly<
|
|
326
|
+
export declare function executeUseGlobal<R>(callback: () => R): (() => Readonly<R & { init(): Readonly<R>; destroyExecute?(): void; }>) | (() => Readonly<R & { init(): Readonly<R>; destroyExecute?(): void; }>);
|
|
327
|
+
export declare function executeUseProvide<R, O extends any[]>(callback: (...args: O) => R): ((...args: O) => Readonly<R & { init(): Readonly<R>; destroyExecute?(): void; }>) | (() => Readonly<R & { init(): Readonly<R>; destroyExecute?(): void; }>);
|
|
328
|
+
export declare function executeUseLocal<R, O extends any[]>(callback: (...args: O) => R): ((...args: O) => Readonly<R & { init(): Readonly<R>; destroyExecute?(): void; }>) | (() => Readonly<R & { init(): Readonly<R>; destroyExecute?(): void; }>);
|
|
472
329
|
export declare function executeUseGlobalInit(): void;
|
|
473
330
|
|
|
474
331
|
// File: src/functions/getInject.d.ts
|
|
@@ -513,6 +370,73 @@ export declare function toBind<R extends ItemList = ItemList>(extra: ItemList, v
|
|
|
513
370
|
// File: src/functions/toBinds.d.ts
|
|
514
371
|
export declare function toBinds<R extends ItemList = ItemList>(...values: (ItemList | undefined)[]): ConstrBind<R>;
|
|
515
372
|
|
|
373
|
+
// File: src/library.d.ts
|
|
374
|
+
export * from './classes/design/DesignAbstract';
|
|
375
|
+
export * from './classes/design/DesignAsyncAbstract';
|
|
376
|
+
export * from './classes/design/DesignChanged';
|
|
377
|
+
export * from './classes/design/DesignComp';
|
|
378
|
+
export * from './classes/design/DesignComponents';
|
|
379
|
+
export * from './classes/design/DesignConstructorAbstract';
|
|
380
|
+
export * from './classes/ref/DatetimeRef';
|
|
381
|
+
export * from './classes/ref/EffectScopeGlobal';
|
|
382
|
+
export * from './classes/ref/EventRef';
|
|
383
|
+
export * from './classes/ref/GeoFlagRef';
|
|
384
|
+
export * from './classes/ref/GeoIntlRef';
|
|
385
|
+
export * from './classes/ref/GeoRef';
|
|
386
|
+
export * from './classes/ref/ListDataRef';
|
|
387
|
+
export * from './classes/ref/RouterItemRef';
|
|
388
|
+
export * from './classes/ref/ScrollbarWidthRef';
|
|
389
|
+
export * from './composables/ref/useApiAsyncRef';
|
|
390
|
+
export * from './composables/ref/useApiDelete';
|
|
391
|
+
export * from './composables/ref/useApiGet';
|
|
392
|
+
export * from './composables/ref/useApiManagementAsyncRef';
|
|
393
|
+
export * from './composables/ref/useApiManagementRef';
|
|
394
|
+
export * from './composables/ref/useApiPost';
|
|
395
|
+
export * from './composables/ref/useApiPut';
|
|
396
|
+
export * from './composables/ref/useApiRef';
|
|
397
|
+
export * from './composables/ref/useApiRequest';
|
|
398
|
+
export * from './composables/ref/useBroadcastValueRef';
|
|
399
|
+
export * from './composables/ref/useCookieRef';
|
|
400
|
+
export * from './composables/ref/useFormattersRef';
|
|
401
|
+
export * from './composables/ref/useGeoIntlRef';
|
|
402
|
+
export * from './composables/ref/useHashRef';
|
|
403
|
+
export * from './composables/ref/useLazyItemByMarginRef';
|
|
404
|
+
export * from './composables/ref/useLazyRef';
|
|
405
|
+
export * from './composables/ref/useLoadingRef';
|
|
406
|
+
export * from './composables/ref/useMeta';
|
|
407
|
+
export * from './composables/ref/useQueryRef';
|
|
408
|
+
export * from './composables/ref/useRouterList';
|
|
409
|
+
export * from './composables/ref/useSearchRef';
|
|
410
|
+
export * from './composables/ref/useSearchValueRef';
|
|
411
|
+
export * from './composables/ref/useSessionRef';
|
|
412
|
+
export * from './composables/ref/useStorageRef';
|
|
413
|
+
export * from './composables/ref/useTranslateRef';
|
|
414
|
+
export * from './functions/basic';
|
|
415
|
+
export * from './functions/computedAsync';
|
|
416
|
+
export * from './functions/computedByLanguage';
|
|
417
|
+
export * from './functions/computedEternity';
|
|
418
|
+
export * from './functions/dxtFunctionalPlugin';
|
|
419
|
+
export * from './functions/executeUse';
|
|
420
|
+
export * from './functions/getInject';
|
|
421
|
+
export * from './functions/getOptions';
|
|
422
|
+
export * from './functions/ref/executeFunctionRef';
|
|
423
|
+
export * from './functions/ref/getApiErrorRef';
|
|
424
|
+
export * from './functions/ref/getBindRef';
|
|
425
|
+
export * from './functions/ref/getRef';
|
|
426
|
+
export * from './functions/ref/render';
|
|
427
|
+
export * from './functions/ref/setRef';
|
|
428
|
+
export * from './functions/ref/toRefItem';
|
|
429
|
+
export * from './functions/render/getBind';
|
|
430
|
+
export * from './functions/render/getClassName';
|
|
431
|
+
export * from './functions/render/getIndexForRender';
|
|
432
|
+
export * from './functions/toBind';
|
|
433
|
+
export * from './functions/toBinds';
|
|
434
|
+
export * from './types/apiTypes';
|
|
435
|
+
export * from './types/constructorTypes';
|
|
436
|
+
export * from './types/listTypes';
|
|
437
|
+
export * from './types/refTypes';
|
|
438
|
+
export * from './types/searchTypes';
|
|
439
|
+
|
|
516
440
|
// File: src/types/apiTypes.d.ts
|
|
517
441
|
export type ApiOptions = ApiMethodItem | RefOrNormal<ApiFetch>;
|
|
518
442
|
export type ApiManagementValue = ApiDefaultValue | ApiDefaultValue[];
|