@prom-ui/core 1.0.0-alpha.5 → 1.0.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/Avatar/package.json +1 -1
- package/Backdrop/package.json +1 -1
- package/Body/package.json +1 -1
- package/BodyProvider/package.json +1 -1
- package/Box/package.json +1 -1
- package/Button/package.json +1 -1
- package/ButtonPageUp/package.json +1 -1
- package/Checkbox/package.json +1 -1
- package/Flex/package.json +1 -1
- package/Grid/package.json +1 -1
- package/Icon/package.json +1 -1
- package/Image/package.json +1 -1
- package/ImageEmoji/package.json +1 -1
- package/Input/package.json +1 -1
- package/InputField/package.json +1 -1
- package/KeyPress/package.json +1 -1
- package/Line/package.json +1 -1
- package/Link/package.json +1 -1
- package/List/package.json +1 -1
- package/Media/package.json +1 -1
- package/OutsideClick/package.json +1 -1
- package/Overlay/package.json +1 -1
- package/Picture/package.json +1 -1
- package/Portal/package.json +1 -1
- package/QRCode/package.json +1 -1
- package/Rating/package.json +1 -1
- package/SafeQuery/cjs/index.development.js +5 -6
- package/SafeQuery/cjs/index.development.v2.js +5 -6
- package/SafeQuery/index.d.ts +9 -6
- package/SafeQuery/package.json +1 -1
- package/Scroll/package.json +1 -1
- package/ScrollControls/package.json +1 -1
- package/SimpleSlider/package.json +1 -1
- package/Skeleton/package.json +1 -1
- package/Spinner/package.json +1 -1
- package/Text/package.json +1 -1
- package/TextEmoji/package.json +1 -1
- package/Tooltip/package.json +1 -1
- package/Tumbler/package.json +1 -1
- package/package.json +2 -2
- package/useDebounce/package.json +1 -1
- package/useIsMounted/package.json +1 -1
- package/useKeyPress/package.json +1 -1
- package/useMedia/package.json +1 -1
- package/useOutsideClick/package.json +1 -1
- package/usePortal/package.json +1 -1
- package/useScrollPosition/package.json +1 -1
package/Avatar/package.json
CHANGED
package/Backdrop/package.json
CHANGED
package/Body/package.json
CHANGED
package/Box/package.json
CHANGED
package/Button/package.json
CHANGED
package/Checkbox/package.json
CHANGED
package/Flex/package.json
CHANGED
package/Grid/package.json
CHANGED
package/Icon/package.json
CHANGED
package/Image/package.json
CHANGED
package/ImageEmoji/package.json
CHANGED
package/Input/package.json
CHANGED
package/InputField/package.json
CHANGED
package/KeyPress/package.json
CHANGED
package/Line/package.json
CHANGED
package/Link/package.json
CHANGED
package/List/package.json
CHANGED
package/Media/package.json
CHANGED
package/Overlay/package.json
CHANGED
package/Picture/package.json
CHANGED
package/Portal/package.json
CHANGED
package/QRCode/package.json
CHANGED
package/Rating/package.json
CHANGED
|
@@ -163,15 +163,14 @@ var SafeQuery = function (_a) {
|
|
|
163
163
|
return setReload(true);
|
|
164
164
|
}
|
|
165
165
|
});
|
|
166
|
-
var renderChildren = function (queryResult) {
|
|
167
|
-
var error = queryResult.error;
|
|
168
|
-
if (error) throw error;
|
|
169
|
-
return children(queryResult);
|
|
170
|
-
};
|
|
171
166
|
return React__namespace.createElement(errcatch.ErrCatch, {
|
|
172
167
|
name: componentErrorName,
|
|
173
168
|
errorComponent: errorComponent
|
|
174
|
-
}, React__namespace.createElement(components.Query, __assign({}, props),
|
|
169
|
+
}, React__namespace.createElement(components.Query, __assign({}, props), function (queryResult) {
|
|
170
|
+
var error = queryResult.error;
|
|
171
|
+
if (error) throw error;
|
|
172
|
+
return children(queryResult);
|
|
173
|
+
}));
|
|
175
174
|
};
|
|
176
175
|
|
|
177
176
|
exports.SafeQuery = SafeQuery;
|
|
@@ -163,15 +163,14 @@ var SafeQuery = function (_a) {
|
|
|
163
163
|
return setReload(true);
|
|
164
164
|
}
|
|
165
165
|
});
|
|
166
|
-
var renderChildren = function (queryResult) {
|
|
167
|
-
var error = queryResult.error;
|
|
168
|
-
if (error) throw error;
|
|
169
|
-
return children(queryResult);
|
|
170
|
-
};
|
|
171
166
|
return React__namespace.createElement(errcatch.ErrCatch, {
|
|
172
167
|
name: componentErrorName,
|
|
173
168
|
errorComponent: errorComponent
|
|
174
|
-
}, React__namespace.createElement(components.Query, __assign({}, props),
|
|
169
|
+
}, React__namespace.createElement(components.Query, __assign({}, props), function (queryResult) {
|
|
170
|
+
var error = queryResult.error;
|
|
171
|
+
if (error) throw error;
|
|
172
|
+
return children(queryResult);
|
|
173
|
+
}));
|
|
175
174
|
};
|
|
176
175
|
|
|
177
176
|
exports.SafeQuery = SafeQuery;
|
package/SafeQuery/index.d.ts
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
export type SafeQuery<TData = any, TVariables extends OperationVariables = OperationVariables> = (props: QueryComponentOptions<TData, TVariables> & {
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export type SafeQueryProps = {
|
|
3
|
+
/** Название компонента в тексте с ошибкой */
|
|
5
4
|
componentErrorName?: string;
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
/** React children */
|
|
6
|
+
children: (arg: any) => JSX.Element;
|
|
7
|
+
query: any;
|
|
8
|
+
variables?: any;
|
|
9
|
+
};
|
|
10
|
+
export declare const SafeQuery: React.FC<SafeQueryProps>;
|
package/SafeQuery/package.json
CHANGED
package/Scroll/package.json
CHANGED
package/Skeleton/package.json
CHANGED
package/Spinner/package.json
CHANGED
package/Text/package.json
CHANGED
package/TextEmoji/package.json
CHANGED
package/Tooltip/package.json
CHANGED
package/Tumbler/package.json
CHANGED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prom-ui/core",
|
|
3
3
|
"author": "e.marchenko",
|
|
4
|
-
"version": "1.0.0
|
|
4
|
+
"version": "1.0.0",
|
|
5
5
|
"description": "core ui blocks",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"test": "jest --verbose ./src",
|
|
@@ -69,5 +69,5 @@
|
|
|
69
69
|
"optional": true
|
|
70
70
|
}
|
|
71
71
|
},
|
|
72
|
-
"gitHead": "
|
|
72
|
+
"gitHead": "d8cc5607a081df94b41dc37be774e58917f61d94"
|
|
73
73
|
}
|
package/useDebounce/package.json
CHANGED
package/useKeyPress/package.json
CHANGED
package/useMedia/package.json
CHANGED
package/usePortal/package.json
CHANGED