xenopomp-essentials 0.2.1 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.d.mts +28 -10
- package/index.d.ts +28 -10
- package/next/index.d.mts +0 -6
- package/next/index.d.ts +0 -6
- package/package.json +3 -3
package/index.d.mts
CHANGED
|
@@ -55,9 +55,9 @@ interface NextErrorParams<E extends Error = any> {
|
|
|
55
55
|
/**
|
|
56
56
|
* This type wraps ComponentProps<A> to your FC.
|
|
57
57
|
*
|
|
58
|
-
*
|
|
59
|
-
*
|
|
60
|
-
*
|
|
58
|
+
* - __A__ - element type
|
|
59
|
+
* - __P__ - wrapping props
|
|
60
|
+
* - __Ex__ - excluded component props (for example, if you do not want to include 'children' prop in component)
|
|
61
61
|
*
|
|
62
62
|
* @since 0.0.1
|
|
63
63
|
*
|
|
@@ -183,11 +183,15 @@ type Synchronous<Func> = Func extends Fn ? Func extends (...args: any[]) => Prom
|
|
|
183
183
|
type Writeable<T> = {
|
|
184
184
|
-readonly [P in keyof T]: T[P];
|
|
185
185
|
};
|
|
186
|
+
/**
|
|
187
|
+
* @deprecated Use {@link WriteableDeep} instead.
|
|
188
|
+
*/
|
|
189
|
+
type DeepWriteable<T> = WriteableDeep<T>;
|
|
186
190
|
/**
|
|
187
191
|
* Removes readonly from type deeply.
|
|
188
192
|
* @since 0.0.1
|
|
189
193
|
*/
|
|
190
|
-
type
|
|
194
|
+
type WriteableDeep<T> = {
|
|
191
195
|
-readonly [P in keyof T]: DeepWriteable<T[P]>;
|
|
192
196
|
};
|
|
193
197
|
|
|
@@ -245,14 +249,18 @@ type ArrayItemType<T> = ArrayType<T>;
|
|
|
245
249
|
type AsyncReturnType<F extends (...args: any[]) => Promise<any>> = Awaited<ReturnType<F>>;
|
|
246
250
|
|
|
247
251
|
/**
|
|
248
|
-
*
|
|
252
|
+
* @deprecated Use {@link InjectDeep} instead.
|
|
253
|
+
*/
|
|
254
|
+
type DeepInject<T, I extends AnyObject> = InjectDeep<T, I>;
|
|
255
|
+
/**
|
|
256
|
+
* Recursively add some type inside all keys of target type.
|
|
249
257
|
*
|
|
250
258
|
* @since 0.0.1
|
|
251
259
|
* @example
|
|
252
260
|
* type Sups = DeepInject<{ supa: { sups: number } }, { _ignore: boolean }>;
|
|
253
261
|
* const asp: Sups = { supa: { sups: 1, _ignore: false }, _ignore: false };
|
|
254
262
|
*/
|
|
255
|
-
type
|
|
263
|
+
type InjectDeep<T, I extends AnyObject> = T extends object ? {
|
|
256
264
|
[K in keyof T]: T[K] extends object ? T[K] & I & DeepInject<T[K], I> : T[K];
|
|
257
265
|
} & I : T;
|
|
258
266
|
|
|
@@ -438,6 +446,19 @@ type Lenient<T> = T & {};
|
|
|
438
446
|
*/
|
|
439
447
|
type LenientAutocomplete<T extends string> = T | Lenient<string>;
|
|
440
448
|
|
|
449
|
+
/**
|
|
450
|
+
* Presents plain object in pretty form.
|
|
451
|
+
*/
|
|
452
|
+
type Prettify<T> = {
|
|
453
|
+
[K in keyof T]: T[K];
|
|
454
|
+
} & {};
|
|
455
|
+
/**
|
|
456
|
+
* Presents object in pretty form recursively.
|
|
457
|
+
*/
|
|
458
|
+
type PrettifyDeep<T> = {
|
|
459
|
+
[K in keyof T]: T[K] extends AnyObject ? Prettify<PrettifyDeep<T[K]>> : T[K];
|
|
460
|
+
};
|
|
461
|
+
|
|
441
462
|
/**
|
|
442
463
|
* Creates pipelines of functions that will be executed only
|
|
443
464
|
* when you will call whole pipeline.
|
|
@@ -536,9 +557,6 @@ declare const transliterate: transliteration.TransliterateFunction;
|
|
|
536
557
|
|
|
537
558
|
/**
|
|
538
559
|
* Constraints number with min and max values.
|
|
539
|
-
* @param num
|
|
540
|
-
* @param min
|
|
541
|
-
* @param max
|
|
542
560
|
*
|
|
543
561
|
* @example Min value
|
|
544
562
|
* console.log({
|
|
@@ -590,4 +608,4 @@ declare const minmax: (num: number, [min, max]: [min: number | undefined, max: n
|
|
|
590
608
|
*/
|
|
591
609
|
declare function jsxDotNotation<Props = EmptyObject, Rest extends Record<string, FC<any>> = EmptyObject>(comp: FC<Props>, rest: Rest): FC<Props> & Rest;
|
|
592
610
|
|
|
593
|
-
export { type AnyFC, type AnyObject, type ArrayItemType, type ArrayType, type AsyncFC, type AsyncReturnType, type AsyncVariableFC, type DataAttributes, type
|
|
611
|
+
export { type AnyFC, type AnyObject, type ArrayItemType, type ArrayType, type AsyncFC, type AsyncReturnType, type AsyncVariableFC, type DataAttributes, type Defined, type EmptyObject, type FCProps, type FcProps, type Fn, type FunctionalChildren, type InjectDeep, type Jsonish, type Lenient, type LenientAutocomplete, type MatchType, type MergeTypes, type Modify, type NextErrorParams, type NextParams, type NextSearchParams, type Nullable, type OneOf, type OnlyFirst, type Preid, type Prettify, type PrettifyDeep, type RecordKey, type RecordValue, type ReplaceReturnType, type SelectivePartial, type SetState, type StrictOmit, type Synchronous, type Undefinable, type VariableFC, type VersionData, type WeakOmit, type Writeable, type WriteableDeep, capitalize, jsxDotNotation, minmax, parseVersion, pipe, transliterate, uncapitalize };
|
package/index.d.ts
CHANGED
|
@@ -55,9 +55,9 @@ interface NextErrorParams<E extends Error = any> {
|
|
|
55
55
|
/**
|
|
56
56
|
* This type wraps ComponentProps<A> to your FC.
|
|
57
57
|
*
|
|
58
|
-
*
|
|
59
|
-
*
|
|
60
|
-
*
|
|
58
|
+
* - __A__ - element type
|
|
59
|
+
* - __P__ - wrapping props
|
|
60
|
+
* - __Ex__ - excluded component props (for example, if you do not want to include 'children' prop in component)
|
|
61
61
|
*
|
|
62
62
|
* @since 0.0.1
|
|
63
63
|
*
|
|
@@ -183,11 +183,15 @@ type Synchronous<Func> = Func extends Fn ? Func extends (...args: any[]) => Prom
|
|
|
183
183
|
type Writeable<T> = {
|
|
184
184
|
-readonly [P in keyof T]: T[P];
|
|
185
185
|
};
|
|
186
|
+
/**
|
|
187
|
+
* @deprecated Use {@link WriteableDeep} instead.
|
|
188
|
+
*/
|
|
189
|
+
type DeepWriteable<T> = WriteableDeep<T>;
|
|
186
190
|
/**
|
|
187
191
|
* Removes readonly from type deeply.
|
|
188
192
|
* @since 0.0.1
|
|
189
193
|
*/
|
|
190
|
-
type
|
|
194
|
+
type WriteableDeep<T> = {
|
|
191
195
|
-readonly [P in keyof T]: DeepWriteable<T[P]>;
|
|
192
196
|
};
|
|
193
197
|
|
|
@@ -245,14 +249,18 @@ type ArrayItemType<T> = ArrayType<T>;
|
|
|
245
249
|
type AsyncReturnType<F extends (...args: any[]) => Promise<any>> = Awaited<ReturnType<F>>;
|
|
246
250
|
|
|
247
251
|
/**
|
|
248
|
-
*
|
|
252
|
+
* @deprecated Use {@link InjectDeep} instead.
|
|
253
|
+
*/
|
|
254
|
+
type DeepInject<T, I extends AnyObject> = InjectDeep<T, I>;
|
|
255
|
+
/**
|
|
256
|
+
* Recursively add some type inside all keys of target type.
|
|
249
257
|
*
|
|
250
258
|
* @since 0.0.1
|
|
251
259
|
* @example
|
|
252
260
|
* type Sups = DeepInject<{ supa: { sups: number } }, { _ignore: boolean }>;
|
|
253
261
|
* const asp: Sups = { supa: { sups: 1, _ignore: false }, _ignore: false };
|
|
254
262
|
*/
|
|
255
|
-
type
|
|
263
|
+
type InjectDeep<T, I extends AnyObject> = T extends object ? {
|
|
256
264
|
[K in keyof T]: T[K] extends object ? T[K] & I & DeepInject<T[K], I> : T[K];
|
|
257
265
|
} & I : T;
|
|
258
266
|
|
|
@@ -438,6 +446,19 @@ type Lenient<T> = T & {};
|
|
|
438
446
|
*/
|
|
439
447
|
type LenientAutocomplete<T extends string> = T | Lenient<string>;
|
|
440
448
|
|
|
449
|
+
/**
|
|
450
|
+
* Presents plain object in pretty form.
|
|
451
|
+
*/
|
|
452
|
+
type Prettify<T> = {
|
|
453
|
+
[K in keyof T]: T[K];
|
|
454
|
+
} & {};
|
|
455
|
+
/**
|
|
456
|
+
* Presents object in pretty form recursively.
|
|
457
|
+
*/
|
|
458
|
+
type PrettifyDeep<T> = {
|
|
459
|
+
[K in keyof T]: T[K] extends AnyObject ? Prettify<PrettifyDeep<T[K]>> : T[K];
|
|
460
|
+
};
|
|
461
|
+
|
|
441
462
|
/**
|
|
442
463
|
* Creates pipelines of functions that will be executed only
|
|
443
464
|
* when you will call whole pipeline.
|
|
@@ -536,9 +557,6 @@ declare const transliterate: transliteration.TransliterateFunction;
|
|
|
536
557
|
|
|
537
558
|
/**
|
|
538
559
|
* Constraints number with min and max values.
|
|
539
|
-
* @param num
|
|
540
|
-
* @param min
|
|
541
|
-
* @param max
|
|
542
560
|
*
|
|
543
561
|
* @example Min value
|
|
544
562
|
* console.log({
|
|
@@ -590,4 +608,4 @@ declare const minmax: (num: number, [min, max]: [min: number | undefined, max: n
|
|
|
590
608
|
*/
|
|
591
609
|
declare function jsxDotNotation<Props = EmptyObject, Rest extends Record<string, FC<any>> = EmptyObject>(comp: FC<Props>, rest: Rest): FC<Props> & Rest;
|
|
592
610
|
|
|
593
|
-
export { type AnyFC, type AnyObject, type ArrayItemType, type ArrayType, type AsyncFC, type AsyncReturnType, type AsyncVariableFC, type DataAttributes, type
|
|
611
|
+
export { type AnyFC, type AnyObject, type ArrayItemType, type ArrayType, type AsyncFC, type AsyncReturnType, type AsyncVariableFC, type DataAttributes, type Defined, type EmptyObject, type FCProps, type FcProps, type Fn, type FunctionalChildren, type InjectDeep, type Jsonish, type Lenient, type LenientAutocomplete, type MatchType, type MergeTypes, type Modify, type NextErrorParams, type NextParams, type NextSearchParams, type Nullable, type OneOf, type OnlyFirst, type Preid, type Prettify, type PrettifyDeep, type RecordKey, type RecordValue, type ReplaceReturnType, type SelectivePartial, type SetState, type StrictOmit, type Synchronous, type Undefinable, type VariableFC, type VersionData, type WeakOmit, type Writeable, type WriteableDeep, capitalize, jsxDotNotation, minmax, parseVersion, pipe, transliterate, uncapitalize };
|
package/next/index.d.mts
CHANGED
|
@@ -40,12 +40,6 @@ interface MetrikaProps {
|
|
|
40
40
|
* This component allows you to use Yandex.Metrika
|
|
41
41
|
* in your Next.js projects.
|
|
42
42
|
*
|
|
43
|
-
* @param id
|
|
44
|
-
* @param clickMap
|
|
45
|
-
* @param trackLinks
|
|
46
|
-
* @param accurateTrackBounce
|
|
47
|
-
* @constructor
|
|
48
|
-
*
|
|
49
43
|
* @since 0.0.1
|
|
50
44
|
*
|
|
51
45
|
* @example
|
package/next/index.d.ts
CHANGED
|
@@ -40,12 +40,6 @@ interface MetrikaProps {
|
|
|
40
40
|
* This component allows you to use Yandex.Metrika
|
|
41
41
|
* in your Next.js projects.
|
|
42
42
|
*
|
|
43
|
-
* @param id
|
|
44
|
-
* @param clickMap
|
|
45
|
-
* @param trackLinks
|
|
46
|
-
* @param accurateTrackBounce
|
|
47
|
-
* @constructor
|
|
48
|
-
*
|
|
49
43
|
* @since 0.0.1
|
|
50
44
|
*
|
|
51
45
|
* @example
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "xenopomp-essentials",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.2",
|
|
4
4
|
"author": "XenoPOMP <101574433+XenoPOMP@users.noreply.github.com>",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -74,8 +74,8 @@
|
|
|
74
74
|
"react-dom": "^19.0.0",
|
|
75
75
|
"tsd": "^0.31.2",
|
|
76
76
|
"unbuild": "^3.3.1",
|
|
77
|
-
"vite": "
|
|
77
|
+
"vite": "7.1.5",
|
|
78
78
|
"vite-tsconfig-paths": "^5.1.4",
|
|
79
|
-
"vitest": "^3.
|
|
79
|
+
"vitest": "^3.2.4"
|
|
80
80
|
}
|
|
81
81
|
}
|