@nolwenture/formik-jsonschema-form 1.0.0-beta.14 → 1.0.0-beta.16
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/dist/cjs/Form/index.js +1 -0
- package/dist/cjs/utils/getTitleAndDescription.js +6 -5
- package/dist/esm/Form/index.js +1 -0
- package/dist/esm/utils/getTitleAndDescription.js +6 -5
- package/dist/types/Form/index.d.ts +1 -0
- package/dist/types/utils/getTitleAndDescription.d.ts +1 -1
- package/package.json +1 -1
package/dist/cjs/Form/index.js
CHANGED
|
@@ -27,3 +27,4 @@ Object.defineProperty(exports, "FormComponents", { enumerable: true, get: functi
|
|
|
27
27
|
const templates_1 = require("./templates");
|
|
28
28
|
Object.defineProperty(exports, "FormTemplates", { enumerable: true, get: function () { return templates_1.templates; } });
|
|
29
29
|
__exportStar(require("./Form"), exports);
|
|
30
|
+
__exportStar(require("./FormRegistry"), exports);
|
|
@@ -2,11 +2,12 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.getDescription = exports.getTitle = void 0;
|
|
4
4
|
const getTitle = ({ title, uiSchema, schema, name, }) => {
|
|
5
|
-
return
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return uiSchema?.["ui:options"]?.hideTitle
|
|
6
|
+
? undefined
|
|
7
|
+
: title ||
|
|
8
|
+
uiSchema?.["ui:title"] ||
|
|
9
|
+
schema?.title ||
|
|
10
|
+
name?.split(".")[name?.split(".").length - 1];
|
|
10
11
|
};
|
|
11
12
|
exports.getTitle = getTitle;
|
|
12
13
|
const getDescription = ({ description, uiSchema, schema, }) => {
|
package/dist/esm/Form/index.js
CHANGED
|
@@ -7,4 +7,5 @@ import { fields as FormFields } from "./fields";
|
|
|
7
7
|
import { components as FormComponents } from "./components";
|
|
8
8
|
import { templates as FormTemplates } from "./templates";
|
|
9
9
|
export * from "./Form";
|
|
10
|
+
export * from "./FormRegistry";
|
|
10
11
|
export { FormComponents, FormFields, FormTemplates };
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
export const getTitle = ({ title, uiSchema, schema, name, }) => {
|
|
2
|
-
return
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
return uiSchema?.["ui:options"]?.hideTitle
|
|
3
|
+
? undefined
|
|
4
|
+
: title ||
|
|
5
|
+
uiSchema?.["ui:title"] ||
|
|
6
|
+
schema?.title ||
|
|
7
|
+
name?.split(".")[name?.split(".").length - 1];
|
|
7
8
|
};
|
|
8
9
|
export const getDescription = ({ description, uiSchema, schema, }) => {
|
|
9
10
|
return (description ||
|
|
@@ -7,5 +7,6 @@ import { fields as FormFields } from "./fields";
|
|
|
7
7
|
import { components as FormComponents } from "./components";
|
|
8
8
|
import { templates as FormTemplates } from "./templates";
|
|
9
9
|
export * from "./Form";
|
|
10
|
+
export * from "./FormRegistry";
|
|
10
11
|
export { FormComponents, FormFields, FormTemplates };
|
|
11
12
|
export type * from "./types";
|
|
@@ -4,7 +4,7 @@ export declare const getTitle: ({ title, uiSchema, schema, name, }: {
|
|
|
4
4
|
uiSchema?: UiSchema;
|
|
5
5
|
schema?: Schema;
|
|
6
6
|
name?: string;
|
|
7
|
-
}) => string | number | true |
|
|
7
|
+
}) => string | number | true | import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>> | Iterable<import("react").ReactNode> | undefined;
|
|
8
8
|
export declare const getDescription: ({ description, uiSchema, schema, }: {
|
|
9
9
|
description?: string;
|
|
10
10
|
uiSchema?: UiSchema;
|
package/package.json
CHANGED