@factorialco/rjsf-f0 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.
@@ -0,0 +1,11 @@
1
+ import { FormProps } from '@rjsf/core';
2
+ import { ComponentType } from '../node_modules/@types/react';
3
+ /** Builds a `Form` bound to the f0 theme. */
4
+ export declare function generateForm(): ComponentType<FormProps>;
5
+ /**
6
+ * A ready-made `Form` using the f0 theme, for consumers that render RJSF
7
+ * directly. Consumers of `@factorialco/fcode-react-forms` pass `rjsfTheme={Theme}`
8
+ * instead so they keep the SDK's spec fetching and submit handling.
9
+ */
10
+ declare const Form: ComponentType<FormProps<any, import('@rjsf/utils').RJSFSchema, any>>;
11
+ export default Form;
@@ -0,0 +1,2 @@
1
+ export { default as Form, generateForm } from './form';
2
+ export { Templates, Theme, Widgets, generateTheme } from './theme';
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,11 @@
1
+ import { default as React } from '../../node_modules/@types/react';
2
+ import { IconButtonProps, SubmitButtonProps, TemplatesType } from '@rjsf/utils';
3
+ export declare function CopyButton(props: IconButtonProps): React.JSX.Element;
4
+ export declare function MoveUpButton(props: IconButtonProps): React.JSX.Element;
5
+ export declare function MoveDownButton(props: IconButtonProps): React.JSX.Element;
6
+ export declare function RemoveButton(props: IconButtonProps): React.JSX.Element;
7
+ export declare function ClearButton(props: IconButtonProps): React.JSX.Element;
8
+ export declare function AddButton(props: IconButtonProps): React.JSX.Element;
9
+ /** The form's submit button. Relies on the native submit behaviour. */
10
+ export declare function SubmitButton({ uiSchema }: SubmitButtonProps): React.JSX.Element | null;
11
+ export declare const ButtonTemplates: TemplatesType['ButtonTemplates'];
@@ -0,0 +1,15 @@
1
+ import { default as React } from '../../node_modules/@types/react';
2
+ import { FieldTemplateProps } from '@rjsf/utils';
3
+ /**
4
+ * One field row.
5
+ *
6
+ * The label lives here rather than on the f0 control because Factorial Code form
7
+ * labels may contain markdown, which f0 fields take as a plain string. Widgets
8
+ * therefore hide the f0 label and keep the plain text only as the control's
9
+ * accessible name.
10
+ *
11
+ * `schema.rawHtml.before/after` is a Factorial Code schema extension that lets a
12
+ * form author wrap a field in their own markup; it is sanitized before render
13
+ * and simply absent for schemas that do not use it.
14
+ */
15
+ export declare function FieldTemplate(props: FieldTemplateProps): React.JSX.Element;
@@ -0,0 +1,21 @@
1
+ import { default as React } from '../../node_modules/@types/react';
2
+ import { ArrayFieldItemButtonsTemplateProps, ArrayFieldItemTemplateProps, ArrayFieldTemplateProps, ObjectFieldTemplateProps } from '@rjsf/utils';
3
+ /** Renders an object's title, description and property rows. */
4
+ export declare function ObjectFieldTemplate(props: ObjectFieldTemplateProps): React.JSX.Element | null;
5
+ /** Renders an array's title, description, item rows and add button. */
6
+ export declare function ArrayFieldTemplate(props: ArrayFieldTemplateProps): React.JSX.Element;
7
+ /** One array item: the item content, then its toolbar. */
8
+ export declare function ArrayFieldItemTemplate(props: ArrayFieldItemTemplateProps): React.JSX.Element;
9
+ /** Move/copy/remove buttons for an array item. */
10
+ export declare function ArrayFieldItemButtonsTemplate(props: ArrayFieldItemButtonsTemplateProps): React.JSX.Element;
11
+ /** Layout container for RJSF's grid feature. */
12
+ export declare function GridTemplate({ children, className, column, ...rest }: {
13
+ children?: React.ReactNode;
14
+ className?: string;
15
+ column?: boolean;
16
+ }): React.JSX.Element;
17
+ /** Wrapper around a oneOf/anyOf selector and the selected variant. */
18
+ export declare function MultiSchemaFieldTemplate({ selector, optionSchemaField, }: {
19
+ selector: React.ReactNode;
20
+ optionSchemaField: React.ReactNode;
21
+ }): React.JSX.Element;
@@ -0,0 +1,23 @@
1
+ import { default as React } from '../../node_modules/@types/react';
2
+ import { DescriptionFieldProps, ErrorListProps, FieldErrorProps, FieldHelpProps, TitleFieldProps, WrapIfAdditionalTemplateProps } from '@rjsf/utils';
3
+ /** Section title. */
4
+ export declare function TitleFieldTemplate({ id, title, uiSchema, optionalDataControl, }: TitleFieldProps): React.JSX.Element | null;
5
+ /** Section (object/array level) description. */
6
+ export declare function DescriptionFieldTemplate({ id, description, }: DescriptionFieldProps): React.JSX.Element | null;
7
+ /**
8
+ * Per-field errors.
9
+ *
10
+ * f0 controls render their own error message, so this only covers the cases f0
11
+ * cannot show inline (multiple messages, and controls rendered as raw
12
+ * primitives).
13
+ */
14
+ export declare function FieldErrorTemplate({ errors, fieldPathId, }: FieldErrorProps): React.JSX.Element | null;
15
+ /** Renders a `ui:help` directive under the control. */
16
+ export declare function FieldHelpTemplate({ fieldPathId, help }: FieldHelpProps): React.JSX.Element | null;
17
+ /** Form-level error summary. */
18
+ export declare function ErrorListTemplate({ errors, registry }: ErrorListProps): React.JSX.Element;
19
+ /**
20
+ * Wraps every field row, and for `additionalProperties` entries also renders the
21
+ * key input and the remove button.
22
+ */
23
+ export declare function WrapIfAdditionalTemplate(props: WrapIfAdditionalTemplateProps): React.JSX.Element;
@@ -0,0 +1,54 @@
1
+ import { ThemeProps } from '@rjsf/core';
2
+ import { FieldTemplate } from './templates/field-template';
3
+ import { DescriptionFieldTemplate, ErrorListTemplate, FieldErrorTemplate, FieldHelpTemplate, TitleFieldTemplate, WrapIfAdditionalTemplate } from './templates/misc-templates';
4
+ import { ArrayFieldItemButtonsTemplate, ArrayFieldItemTemplate, ArrayFieldTemplate, GridTemplate, MultiSchemaFieldTemplate, ObjectFieldTemplate } from './templates/layout-templates';
5
+ import { BaseInputTemplate, TextareaWidget } from './widgets/input-widgets';
6
+ import { CheckboxWidget, CheckboxesWidget, RadioWidget, SelectWidget } from './widgets/choice-widgets';
7
+ export declare const Templates: {
8
+ ArrayFieldItemButtonsTemplate: typeof ArrayFieldItemButtonsTemplate;
9
+ ArrayFieldItemTemplate: typeof ArrayFieldItemTemplate;
10
+ ArrayFieldTemplate: typeof ArrayFieldTemplate;
11
+ BaseInputTemplate: typeof BaseInputTemplate;
12
+ ButtonTemplates: {
13
+ SubmitButton: import('../node_modules/@types/react').ComponentType<import('@rjsf/utils').SubmitButtonProps<any, import('@rjsf/utils').RJSFSchema, any>>;
14
+ AddButton: import('../node_modules/@types/react').ComponentType<import('@rjsf/utils').IconButtonProps<any, import('@rjsf/utils').RJSFSchema, any>>;
15
+ CopyButton: import('../node_modules/@types/react').ComponentType<import('@rjsf/utils').IconButtonProps<any, import('@rjsf/utils').RJSFSchema, any>>;
16
+ MoveDownButton: import('../node_modules/@types/react').ComponentType<import('@rjsf/utils').IconButtonProps<any, import('@rjsf/utils').RJSFSchema, any>>;
17
+ MoveUpButton: import('../node_modules/@types/react').ComponentType<import('@rjsf/utils').IconButtonProps<any, import('@rjsf/utils').RJSFSchema, any>>;
18
+ RemoveButton: import('../node_modules/@types/react').ComponentType<import('@rjsf/utils').IconButtonProps<any, import('@rjsf/utils').RJSFSchema, any>>;
19
+ ClearButton: import('../node_modules/@types/react').ComponentType<import('@rjsf/utils').IconButtonProps<any, import('@rjsf/utils').RJSFSchema, any>>;
20
+ };
21
+ DescriptionFieldTemplate: typeof DescriptionFieldTemplate;
22
+ ErrorListTemplate: typeof ErrorListTemplate;
23
+ FieldErrorTemplate: typeof FieldErrorTemplate;
24
+ FieldHelpTemplate: typeof FieldHelpTemplate;
25
+ FieldTemplate: typeof FieldTemplate;
26
+ GridTemplate: typeof GridTemplate;
27
+ MultiSchemaFieldTemplate: typeof MultiSchemaFieldTemplate;
28
+ ObjectFieldTemplate: typeof ObjectFieldTemplate;
29
+ TitleFieldTemplate: typeof TitleFieldTemplate;
30
+ WrapIfAdditionalTemplate: typeof WrapIfAdditionalTemplate;
31
+ };
32
+ export declare const Widgets: {
33
+ CheckboxWidget: typeof CheckboxWidget;
34
+ CheckboxesWidget: typeof CheckboxesWidget;
35
+ RadioWidget: typeof RadioWidget;
36
+ SelectWidget: typeof SelectWidget;
37
+ TextareaWidget: typeof TextareaWidget;
38
+ };
39
+ /**
40
+ * Builds the theme. Present for parity with the official RJSF theme packages,
41
+ * whose `generateTheme()` exists so the theme can be typed against a specific
42
+ * schema; here the templates are not schema-generic, so it returns the same
43
+ * object every time.
44
+ */
45
+ export declare function generateTheme(): ThemeProps;
46
+ /**
47
+ * The f0 theme for react-jsonschema-form.
48
+ *
49
+ * Anything not listed in `Templates`/`Widgets` falls through to `@rjsf/core`'s
50
+ * own implementation. That is deliberate for the file widget, which keeps RJSF's
51
+ * native `<input type="file">` because the surrounding SDK exchanges uploads as
52
+ * `data:` URLs, and f0's file field is built around an upload hook instead.
53
+ */
54
+ export declare const Theme: ThemeProps;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Form labels may contain markdown, which `FieldTemplate` renders above the
3
+ * control. The f0 field still needs a plain string for the control's accessible
4
+ * name, so the markdown syntax is stripped rather than shown verbatim.
5
+ */
6
+ export declare function toPlainText(label: string | undefined): string;
7
+ /** True when the label needs markdown rendering rather than plain text. */
8
+ export declare function hasMarkdown(label: string | undefined): boolean;
@@ -0,0 +1,2 @@
1
+ import { Options as ReactMarkdownProps } from 'react-markdown';
2
+ export declare function MarkdownContent(props: ReactMarkdownProps): import("react").JSX.Element;
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Sanitizes authored HTML so it can be rendered without executing scripts.
3
+ *
4
+ * @param dirty - The HTML string as authored in the schema or returned by a
5
+ * process execution.
6
+ * @returns The same markup with every script-execution vector removed.
7
+ */
8
+ export declare function sanitizeHtml(dirty: string): string;
@@ -0,0 +1,18 @@
1
+ import { default as React } from '../../node_modules/@types/react';
2
+ import { WidgetProps } from '@rjsf/utils';
3
+ /** Dropdown for enum properties (and for multi-select arrays). */
4
+ export declare function SelectWidget(props: WidgetProps): React.JSX.Element;
5
+ /**
6
+ * A labelled checkbox. Uses the `F0Checkbox` primitive rather than an
7
+ * `F0FormField` so a markdown label can sit beside the box.
8
+ */
9
+ export declare function CheckboxWidget({ id, value, label, hideLabel, disabled, readonly, onChange, }: WidgetProps): React.JSX.Element;
10
+ /** Checkbox group for an array of enum values. */
11
+ export declare function CheckboxesWidget({ id, disabled, readonly, options, value, onChange, }: WidgetProps): React.JSX.Element;
12
+ /**
13
+ * Radio group.
14
+ *
15
+ * f0 has no radio primitive; its equivalent for "pick exactly one" is the
16
+ * card select, which renders the options as a grouped set of selectable rows.
17
+ */
18
+ export declare function RadioWidget(props: WidgetProps): React.JSX.Element;
@@ -0,0 +1,22 @@
1
+ import { default as React } from '../../node_modules/@types/react';
2
+ import { WidgetProps } from '@rjsf/utils';
3
+ /**
4
+ * Shared bridge from an RJSF widget to `F0FormField`.
5
+ *
6
+ * RJSF keeps ownership of validation: the messages it produces are passed down
7
+ * as `error`/`errorMessage` rather than letting f0 (which validates with zod)
8
+ * derive its own. The label is hidden because `FieldTemplate` renders it above
9
+ * the control to support markdown; the plain-text label is still handed to f0 so
10
+ * the control keeps an accessible name.
11
+ */
12
+ export interface F0FieldBridgeProps extends WidgetProps {
13
+ /** The f0 field descriptor minus the parts derived from the RJSF props. */
14
+ field: Record<string, unknown> & {
15
+ type: string;
16
+ };
17
+ /** Converts the RJSF value into what the f0 control expects. */
18
+ toFieldValue?: (value: unknown) => unknown;
19
+ /** Converts what the f0 control emits back into the RJSF value. */
20
+ fromFieldValue?: (value: unknown) => unknown;
21
+ }
22
+ export declare function F0FieldBridge({ field, toFieldValue, fromFieldValue, id, label, value, required, disabled, readonly, placeholder, rawErrors, onChange, onBlur, }: F0FieldBridgeProps): React.JSX.Element;
@@ -0,0 +1,10 @@
1
+ import { default as React } from '../../node_modules/@types/react';
2
+ import { BaseInputTemplateProps, WidgetProps } from '@rjsf/utils';
3
+ /**
4
+ * Renders every `<input>`-based widget: text, email, url, password, number,
5
+ * date, datetime and time all route through here, as they do in RJSF's own
6
+ * themes.
7
+ */
8
+ export declare function BaseInputTemplate(props: BaseInputTemplateProps): React.JSX.Element;
9
+ /** Multi-line text. */
10
+ export declare function TextareaWidget(props: WidgetProps): React.JSX.Element;
@@ -0,0 +1,257 @@
1
+ /*
2
+ * Layout-only stylesheet for the f0 RJSF theme.
3
+ *
4
+ * Every colour, font and control style comes from f0 itself (the host app
5
+ * already imports `@factorialco/f0-react/dist/styles.css`); this file only
6
+ * spaces the pieces RJSF composes — rows, arrays, and the label/help text that
7
+ * the theme renders instead of letting f0 render it.
8
+ *
9
+ * There is deliberately no `all: revert` reset here: unlike the SDK's standalone
10
+ * stylesheet, this theme renders inside an app that already owns its styles.
11
+ */
12
+
13
+ /*
14
+ * f0's own control dimensions, which the layout below has to line up with.
15
+ * Kept as variables so the magic numbers are named rather than repeated.
16
+ */
17
+ :root {
18
+ /* Height of an f0 input / select / date control. */
19
+ --rjsf-f0-control-height: 2.5rem;
20
+ /* Height of an f0 `size="sm"` button, used for the array item toolbar. */
21
+ --rjsf-f0-small-button-height: 1.5rem;
22
+ }
23
+
24
+ .rjsf-f0-field {
25
+ display: flex;
26
+ flex-direction: column;
27
+ /* Matches the `space-y-2` f0 puts between its own label and control. */
28
+ gap: 0.5rem;
29
+ }
30
+
31
+ .rjsf-f0-label {
32
+ font-size: 1rem;
33
+ font-weight: 500;
34
+ line-height: 1.5;
35
+ color: var(--f1-foreground-secondary, inherit);
36
+ }
37
+
38
+ .rjsf-f0-label p,
39
+ .rjsf-f0-help p,
40
+ .rjsf-f0-section-description p {
41
+ margin: 0;
42
+ }
43
+
44
+ .rjsf-f0-help,
45
+ .rjsf-f0-section-description {
46
+ font-size: 0.875rem;
47
+ color: var(--f1-foreground-secondary, inherit);
48
+ }
49
+
50
+ /*
51
+ * Descriptions are authored in markdown, so they can contain lists. Host apps
52
+ * built on Tailwind reset list padding globally, which leaves the markers
53
+ * hanging outside the text block — indent them back.
54
+ */
55
+ .rjsf-f0-help ul,
56
+ .rjsf-f0-help ol,
57
+ .rjsf-f0-section-description ul,
58
+ .rjsf-f0-section-description ol {
59
+ margin: 0.25rem 0 0;
60
+ padding-left: 1.25rem;
61
+ list-style-position: outside;
62
+ }
63
+
64
+ .rjsf-f0-help ul,
65
+ .rjsf-f0-section-description ul {
66
+ list-style-type: disc;
67
+ }
68
+
69
+ .rjsf-f0-help ol,
70
+ .rjsf-f0-section-description ol {
71
+ list-style-type: decimal;
72
+ }
73
+
74
+ .rjsf-f0-help li + li,
75
+ .rjsf-f0-section-description li + li {
76
+ margin-top: 0.125rem;
77
+ }
78
+
79
+ .rjsf-f0-errors {
80
+ margin: 0;
81
+ padding-left: 1.1rem;
82
+ font-size: 0.875rem;
83
+ color: var(--f1-foreground-critical, #b3261e);
84
+ }
85
+
86
+ .rjsf-f0-object,
87
+ .rjsf-f0-array {
88
+ display: flex;
89
+ flex-direction: column;
90
+ gap: 1rem;
91
+ }
92
+
93
+ .rjsf-f0-row + .rjsf-f0-row {
94
+ margin-top: 0;
95
+ }
96
+
97
+ .rjsf-f0-array-items {
98
+ display: flex;
99
+ flex-direction: column;
100
+ gap: 0.75rem;
101
+ }
102
+
103
+ .rjsf-f0-array-item {
104
+ display: flex;
105
+ align-items: flex-end;
106
+ gap: 0.5rem;
107
+ }
108
+
109
+ .rjsf-f0-array-item-content {
110
+ flex: 1;
111
+ min-width: 0;
112
+ }
113
+
114
+ /*
115
+ * For a scalar item the toolbar sits beside a single field (label above
116
+ * control), so it is bottom-aligned to land on the control's row, then lifted by
117
+ * half the difference between the control and the buttons to centre it on that
118
+ * control.
119
+ */
120
+ .rjsf-f0-array-item-toolbar {
121
+ display: flex;
122
+ gap: 0.25rem;
123
+ padding-bottom: calc(
124
+ (var(--rjsf-f0-control-height) - var(--rjsf-f0-small-button-height)) / 2
125
+ );
126
+ }
127
+
128
+ /*
129
+ * An item holding an object or a nested array is a block of several rows.
130
+ * Bottom-aligning there would leave the buttons stranded next to whatever the
131
+ * last row happens to be, so they go at the top, alongside the item's title.
132
+ */
133
+ .rjsf-f0-array-item-composite {
134
+ align-items: flex-start;
135
+ }
136
+
137
+ .rjsf-f0-array-item-composite .rjsf-f0-array-item-toolbar {
138
+ padding-bottom: 0;
139
+ }
140
+
141
+ .rjsf-f0-add {
142
+ display: flex;
143
+ }
144
+
145
+ /* The submit button is a sibling of the field list, so it gets no row gap. */
146
+ .rjsf-f0-submit {
147
+ display: flex;
148
+ margin-top: 1.5rem;
149
+ }
150
+
151
+ /*
152
+ * `gap` matches the `pl-2.5` f0 puts between a checkbox and its own label, so a
153
+ * markdown label (rendered here) lines up with a plain one (rendered by f0).
154
+ */
155
+ .rjsf-f0-checkbox {
156
+ display: flex;
157
+ align-items: center;
158
+ gap: 0.625rem;
159
+ }
160
+
161
+ .rjsf-f0-checkboxes {
162
+ display: flex;
163
+ flex-direction: column;
164
+ gap: 0.5rem;
165
+ }
166
+
167
+ .rjsf-f0-checkbox-label {
168
+ cursor: pointer;
169
+ }
170
+
171
+ .rjsf-f0-additional-property {
172
+ display: flex;
173
+ align-items: flex-end;
174
+ gap: 0.5rem;
175
+ }
176
+
177
+ .rjsf-f0-grid {
178
+ display: flex;
179
+ gap: 1rem;
180
+ }
181
+
182
+ .rjsf-f0-multischema {
183
+ display: flex;
184
+ flex-direction: column;
185
+ gap: 1rem;
186
+ }
187
+
188
+ /*
189
+ * Every selector here must stay namespaced. This sheet is imported app-wide, so
190
+ * a bare utility class would collide with the host app's: an unscoped
191
+ * `.hidden { display: none !important }` silently hid every f0 component using
192
+ * the `hidden md:block` "mobile-only" pattern.
193
+ */
194
+ .rjsf-f0-hidden {
195
+ display: none;
196
+ }
197
+
198
+ /*
199
+ * The SDK's `json` field.
200
+ *
201
+ * It is a Factorial Code field rather than part of this theme, and it styles
202
+ * itself through bare `wrapper` / `textarea` / `shadow` class names that only
203
+ * exist in the SDK's standalone stylesheet — which f0 consumers deliberately do
204
+ * not load. Without them the editor collapsed to a default-width textarea and
205
+ * the `shadow` element, meant to be invisible, rendered the JSON as loose text.
206
+ *
207
+ * These rules are reached through `fcode-field-json`, which the SDK generates
208
+ * into `ui:classNames`, so the generic `wrapper`/`shadow` names stay scoped to
209
+ * this field and cannot collide with the host app.
210
+ *
211
+ * The mechanism is the SDK's: `shadow` mirrors the content in the normal flow to
212
+ * give the wrapper its height, and the textarea is absolutely positioned on top,
213
+ * so the editor grows with the JSON instead of scrolling.
214
+ */
215
+ .fcode-field-json .wrapper {
216
+ position: relative;
217
+ width: 100%;
218
+ overflow: hidden;
219
+ border: 1px solid hsl(var(--neutral-30));
220
+ border-radius: 0.75rem;
221
+ background-color: hsl(var(--neutral-0));
222
+ }
223
+
224
+ .fcode-field-json .textarea,
225
+ .fcode-field-json .shadow {
226
+ box-sizing: border-box;
227
+ padding: 0.5rem 0.75rem;
228
+ font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
229
+ font-size: 0.875rem;
230
+ line-height: 1.5;
231
+ white-space: pre;
232
+ }
233
+
234
+ .fcode-field-json .textarea {
235
+ position: absolute;
236
+ inset: 0;
237
+ width: 100%;
238
+ height: 100%;
239
+ border: 0;
240
+ background: transparent;
241
+ color: inherit;
242
+ resize: none;
243
+ overflow: auto;
244
+ }
245
+
246
+ .fcode-field-json .textarea:focus {
247
+ outline: none;
248
+ }
249
+
250
+ /* Invisible: it exists only to give the wrapper the height of the content. */
251
+ .fcode-field-json .shadow {
252
+ width: 100%;
253
+ min-height: 7.5rem;
254
+ opacity: 0;
255
+ pointer-events: none;
256
+ overflow: hidden;
257
+ }
package/package.json ADDED
@@ -0,0 +1,72 @@
1
+ {
2
+ "name": "@factorialco/rjsf-f0",
3
+ "version": "1.0.0",
4
+ "description": "Factorial f0 theme for react-jsonschema-form: renders RJSF forms with f0 components.",
5
+ "type": "module",
6
+ "homepage": "https://code.factorialhr.com/docs/forms/",
7
+ "author": "Factorial Code Developers <factorial-code@factorial.co>",
8
+ "license": "See LICENSE file",
9
+ "keywords": [
10
+ "rjsf",
11
+ "react-jsonschema-form",
12
+ "json-schema",
13
+ "f0",
14
+ "factorial",
15
+ "theme"
16
+ ],
17
+ "publishConfig": {
18
+ "access": "public"
19
+ },
20
+ "files": [
21
+ "dist",
22
+ "README.md"
23
+ ],
24
+ "main": "./dist/rjsf-f0.cjs.js",
25
+ "module": "./dist/rjsf-f0.es.js",
26
+ "types": "./dist/index.d.ts",
27
+ "exports": {
28
+ ".": {
29
+ "types": "./dist/index.d.ts",
30
+ "import": "./dist/rjsf-f0.es.js",
31
+ "require": "./dist/rjsf-f0.cjs.js"
32
+ },
33
+ "./styles.css": "./dist/styles.css"
34
+ },
35
+ "scripts": {
36
+ "build": "tsc && vitest run && vite build",
37
+ "build:lib": "tsc && vite build",
38
+ "test": "vitest run",
39
+ "watch": "vitest",
40
+ "dev": "vite"
41
+ },
42
+ "peerDependencies": {
43
+ "@factorialco/f0-react": "^4.39.0",
44
+ "@rjsf/core": "^6.7.1",
45
+ "@rjsf/utils": "^6.7.1",
46
+ "react": "^18.3.1 || ^19.0.0",
47
+ "react-dom": "^18.3.1 || ^19.0.0"
48
+ },
49
+ "dependencies": {
50
+ "dompurify": "3.4.12",
51
+ "react-markdown": "^10.1.0"
52
+ },
53
+ "devDependencies": {
54
+ "@factorialco/f0-react": "4.39.1",
55
+ "@rjsf/core": "^6.7.1",
56
+ "@rjsf/utils": "^6.7.1",
57
+ "@rjsf/validator-ajv8": "^6.7.1",
58
+ "@testing-library/jest-dom": "^6.6.3",
59
+ "@testing-library/react": "^16.0.1",
60
+ "@types/node": "^22.0.0",
61
+ "@types/react": "^18.3.12",
62
+ "@types/react-dom": "^18.3.1",
63
+ "@vitejs/plugin-react": "^4.3.4",
64
+ "jsdom": "^28.0.0",
65
+ "react": "18.3.1",
66
+ "react-dom": "18.3.1",
67
+ "typescript": "^5.4.5",
68
+ "vite": "^6",
69
+ "vite-plugin-dts": "^4.3.0",
70
+ "vitest": "^4.0.0"
71
+ }
72
+ }