@rocket.chat/fuselage-forms 1.3.0 → 1.5.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/dist/cjs/Field/Field.d.ts +2 -2
- package/dist/cjs/Field/Field.d.ts.map +1 -1
- package/dist/cjs/Field/FieldContext.d.ts +1 -2
- package/dist/cjs/Field/FieldContext.d.ts.map +1 -1
- package/dist/cjs/Field/FieldContext.js +4 -0
- package/dist/cjs/Field/FieldContext.js.map +1 -1
- package/dist/cjs/Field/FieldDescription.d.ts +2 -2
- package/dist/cjs/Field/FieldDescription.d.ts.map +1 -1
- package/dist/cjs/Field/FieldError.d.ts +2 -2
- package/dist/cjs/Field/FieldError.d.ts.map +1 -1
- package/dist/cjs/Field/FieldHint.d.ts +2 -2
- package/dist/cjs/Field/FieldHint.d.ts.map +1 -1
- package/dist/cjs/Field/FieldProvider.d.ts +2 -2
- package/dist/cjs/Field/FieldProvider.d.ts.map +1 -1
- package/dist/cjs/Field/Label/FieldLabel.d.ts +2 -2
- package/dist/cjs/Field/Label/FieldLabel.d.ts.map +1 -1
- package/dist/cjs/Field/Label/FieldLabel.js +1 -0
- package/dist/cjs/Field/Label/FieldLabel.js.map +1 -1
- package/dist/cjs/Field/Label/HiddenLabel.d.ts +2 -2
- package/dist/cjs/Field/Label/HiddenLabel.d.ts.map +1 -1
- package/dist/cjs/Field/Label/LabelFor.d.ts +2 -2
- package/dist/cjs/Field/Label/LabelFor.d.ts.map +1 -1
- package/dist/cjs/Field/Label/ReferencedLabel.d.ts +2 -2
- package/dist/cjs/Field/Label/ReferencedLabel.d.ts.map +1 -1
- package/dist/cjs/Field/Label/index.d.ts +4 -4
- package/dist/cjs/Field/Label/index.d.ts.map +1 -1
- package/dist/cjs/Field/Label/index.js.map +1 -1
- package/dist/cjs/Field/index.d.ts +5 -5
- package/dist/cjs/Field/index.d.ts.map +1 -1
- package/dist/cjs/Field/index.js.map +1 -1
- package/dist/cjs/Inputs/WrappedInputComponents.d.ts +108 -76
- package/dist/cjs/Inputs/WrappedInputComponents.d.ts.map +1 -1
- package/dist/cjs/Inputs/WrappedInputComponents.js +7 -3
- package/dist/cjs/Inputs/WrappedInputComponents.js.map +1 -1
- package/dist/cjs/Inputs/withLabelHelpers.d.ts +17 -5
- package/dist/cjs/Inputs/withLabelHelpers.d.ts.map +1 -1
- package/dist/cjs/Inputs/withLabelHelpers.js +14 -13
- package/dist/cjs/Inputs/withLabelHelpers.js.map +1 -1
- package/dist/esm/Field/Field.d.ts +2 -2
- package/dist/esm/Field/Field.d.ts.map +1 -1
- package/dist/esm/Field/FieldContext.d.ts +1 -2
- package/dist/esm/Field/FieldContext.d.ts.map +1 -1
- package/dist/esm/Field/FieldContext.js +4 -0
- package/dist/esm/Field/FieldContext.js.map +1 -1
- package/dist/esm/Field/FieldDescription.d.ts +2 -2
- package/dist/esm/Field/FieldDescription.d.ts.map +1 -1
- package/dist/esm/Field/FieldError.d.ts +2 -2
- package/dist/esm/Field/FieldError.d.ts.map +1 -1
- package/dist/esm/Field/FieldHint.d.ts +2 -2
- package/dist/esm/Field/FieldHint.d.ts.map +1 -1
- package/dist/esm/Field/FieldProvider.d.ts +2 -2
- package/dist/esm/Field/FieldProvider.d.ts.map +1 -1
- package/dist/esm/Field/Label/FieldLabel.d.ts +2 -2
- package/dist/esm/Field/Label/FieldLabel.d.ts.map +1 -1
- package/dist/esm/Field/Label/FieldLabel.js +1 -0
- package/dist/esm/Field/Label/FieldLabel.js.map +1 -1
- package/dist/esm/Field/Label/HiddenLabel.d.ts +2 -2
- package/dist/esm/Field/Label/HiddenLabel.d.ts.map +1 -1
- package/dist/esm/Field/Label/LabelFor.d.ts +2 -2
- package/dist/esm/Field/Label/LabelFor.d.ts.map +1 -1
- package/dist/esm/Field/Label/ReferencedLabel.d.ts +2 -2
- package/dist/esm/Field/Label/ReferencedLabel.d.ts.map +1 -1
- package/dist/esm/Field/Label/index.d.ts +4 -4
- package/dist/esm/Field/Label/index.d.ts.map +1 -1
- package/dist/esm/Field/Label/index.js.map +1 -1
- package/dist/esm/Field/index.d.ts +5 -5
- package/dist/esm/Field/index.d.ts.map +1 -1
- package/dist/esm/Field/index.js.map +1 -1
- package/dist/esm/Inputs/WrappedInputComponents.d.ts +108 -76
- package/dist/esm/Inputs/WrappedInputComponents.d.ts.map +1 -1
- package/dist/esm/Inputs/WrappedInputComponents.js +7 -3
- package/dist/esm/Inputs/WrappedInputComponents.js.map +1 -1
- package/dist/esm/Inputs/withLabelHelpers.d.ts +17 -5
- package/dist/esm/Inputs/withLabelHelpers.d.ts.map +1 -1
- package/dist/esm/Inputs/withLabelHelpers.js +14 -13
- package/dist/esm/Inputs/withLabelHelpers.js.map +1 -1
- package/dist/esm/tsdoc-metadata.json +11 -0
- package/package.json +22 -20
|
@@ -1,20 +1,32 @@
|
|
|
1
|
-
import type { ReactNode,
|
|
1
|
+
import type { ReactNode, ComponentType, RefAttributes } from 'react';
|
|
2
2
|
type WithLabelId = {
|
|
3
3
|
id?: string;
|
|
4
4
|
};
|
|
5
|
-
declare function withLabelId<TProps, TRef>(Component:
|
|
5
|
+
declare function withLabelId<TProps, TRef>(Component: ComponentType<TProps & WithLabelId & RefAttributes<TRef>>): {
|
|
6
|
+
(props: TProps & RefAttributes<TRef>): import("react").JSX.Element;
|
|
7
|
+
displayName: string;
|
|
8
|
+
};
|
|
6
9
|
type WithLabelledBy = {
|
|
7
10
|
'aria-labelledby'?: string;
|
|
8
11
|
};
|
|
9
|
-
declare function withAriaLabelledBy<TProps, TRef>(Component:
|
|
12
|
+
declare function withAriaLabelledBy<TProps, TRef>(Component: ComponentType<TProps & WithLabelledBy & RefAttributes<TRef>>): {
|
|
13
|
+
(props: TProps & RefAttributes<TRef>): import("react").JSX.Element;
|
|
14
|
+
displayName: string;
|
|
15
|
+
};
|
|
10
16
|
type WithLabelledByAndId = {
|
|
11
17
|
'aria-labelledby'?: string;
|
|
12
18
|
'id'?: string;
|
|
13
19
|
};
|
|
14
|
-
declare function withAriaLabelledByAndId<TProps, TRef>(Component:
|
|
20
|
+
declare function withAriaLabelledByAndId<TProps, TRef>(Component: ComponentType<TProps & WithLabelledByAndId & RefAttributes<TRef>>): {
|
|
21
|
+
(props: TProps & RefAttributes<TRef>): import("react").JSX.Element;
|
|
22
|
+
displayName: string;
|
|
23
|
+
};
|
|
15
24
|
type WithChildrenLabel = {
|
|
16
25
|
labelChildren: ReactNode;
|
|
17
26
|
};
|
|
18
|
-
declare function withVisuallyHiddenLabel<TProps, TRef>(Component:
|
|
27
|
+
declare function withVisuallyHiddenLabel<TProps, TRef>(Component: ComponentType<TProps & WithChildrenLabel & RefAttributes<TRef>>): {
|
|
28
|
+
(props: TProps & RefAttributes<TRef>): import("react").JSX.Element;
|
|
29
|
+
displayName: string;
|
|
30
|
+
};
|
|
19
31
|
export { withLabelId, withAriaLabelledBy, withAriaLabelledByAndId, withVisuallyHiddenLabel, };
|
|
20
32
|
//# sourceMappingURL=withLabelHelpers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"withLabelHelpers.d.ts","sourceRoot":"","sources":["../../../src/Inputs/withLabelHelpers.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"withLabelHelpers.d.ts","sourceRoot":"","sources":["../../../src/Inputs/withLabelHelpers.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,aAAa,EAAO,aAAa,EAAE,MAAM,OAAO,CAAC;AAU1E,KAAK,WAAW,GAAG;IAAE,EAAE,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAEnC,iBAAS,WAAW,CAAC,MAAM,EAAE,IAAI,EAC/B,SAAS,EAAE,aAAa,CAAC,MAAM,GAAG,WAAW,GAAG,aAAa,CAAC,IAAI,CAAC,CAAC;YAEnC,MAAM,GAAG,aAAa,CAAC,IAAI,CAAC;;EAQ9D;AAED,KAAK,cAAc,GAAG;IAAE,iBAAiB,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAErD,iBAAS,kBAAkB,CAAC,MAAM,EAAE,IAAI,EACtC,SAAS,EAAE,aAAa,CAAC,MAAM,GAAG,cAAc,GAAG,aAAa,CAAC,IAAI,CAAC,CAAC;YAEtC,MAAM,GAAG,aAAa,CAAC,IAAI,CAAC;;EAQ9D;AAED,KAAK,mBAAmB,GAAG;IAAE,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAEzE,iBAAS,uBAAuB,CAAC,MAAM,EAAE,IAAI,EAC3C,SAAS,EAAE,aAAa,CAAC,MAAM,GAAG,mBAAmB,GAAG,aAAa,CAAC,IAAI,CAAC,CAAC;YAE3C,MAAM,GAAG,aAAa,CAAC,IAAI,CAAC;;EAQ9D;AAED,KAAK,iBAAiB,GAAG;IAAE,aAAa,EAAE,SAAS,CAAA;CAAE,CAAC;AAEtD,iBAAS,uBAAuB,CAAC,MAAM,EAAE,IAAI,EAC3C,SAAS,EAAE,aAAa,CAAC,MAAM,GAAG,iBAAiB,GAAG,aAAa,CAAC,IAAI,CAAC,CAAC;YAEzC,MAAM,GAAG,aAAa,CAAC,IAAI,CAAC;;EAgB9D;AAED,OAAO,EACL,WAAW,EACX,kBAAkB,EAClB,uBAAuB,EACvB,uBAAuB,GACxB,CAAC"}
|
|
@@ -5,40 +5,41 @@ exports.withAriaLabelledBy = withAriaLabelledBy;
|
|
|
5
5
|
exports.withAriaLabelledByAndId = withAriaLabelledByAndId;
|
|
6
6
|
exports.withVisuallyHiddenLabel = withVisuallyHiddenLabel;
|
|
7
7
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
8
|
+
// Disabled this flag since we need to wrap multiple components
|
|
9
|
+
/* eslint-disable react/no-multi-comp */
|
|
8
10
|
const fuselage_hooks_1 = require("@rocket.chat/fuselage-hooks");
|
|
9
|
-
const react_1 = require("react");
|
|
10
11
|
const react_aria_1 = require("react-aria");
|
|
11
12
|
const FieldContext_1 = require("../Field/FieldContext");
|
|
12
13
|
function withLabelId(Component) {
|
|
13
|
-
|
|
14
|
+
function WrappedComponent(props) {
|
|
14
15
|
const labelProps = (0, FieldContext_1.useFieldReferencedByInput)();
|
|
15
|
-
return (
|
|
16
|
-
}
|
|
16
|
+
return (0, jsx_runtime_1.jsx)(Component, { ...props, ...labelProps });
|
|
17
|
+
}
|
|
17
18
|
WrappedComponent.displayName = `withLabelId(${Component.displayName ?? Component.name ?? 'InputComponent'})`;
|
|
18
19
|
return WrappedComponent;
|
|
19
20
|
}
|
|
20
21
|
function withAriaLabelledBy(Component) {
|
|
21
|
-
|
|
22
|
+
function WrappedComponent(props) {
|
|
22
23
|
const labelProps = (0, FieldContext_1.useFieldReferencedByLabel)();
|
|
23
|
-
return (
|
|
24
|
-
}
|
|
24
|
+
return (0, jsx_runtime_1.jsx)(Component, { ...props, ...labelProps });
|
|
25
|
+
}
|
|
25
26
|
WrappedComponent.displayName = `withAriaLabelledBy(${Component.displayName ?? Component.name ?? 'InputComponent'})`;
|
|
26
27
|
return WrappedComponent;
|
|
27
28
|
}
|
|
28
29
|
function withAriaLabelledByAndId(Component) {
|
|
29
|
-
|
|
30
|
+
function WrappedComponent(props) {
|
|
30
31
|
const labelProps = (0, FieldContext_1.useFieldReferencedByLabelWithId)();
|
|
31
|
-
return (
|
|
32
|
-
}
|
|
32
|
+
return (0, jsx_runtime_1.jsx)(Component, { ...props, ...labelProps });
|
|
33
|
+
}
|
|
33
34
|
WrappedComponent.displayName = `withAriaLabelledByAndId(${Component.displayName ?? Component.name ?? 'InputComponent'})`;
|
|
34
35
|
return WrappedComponent;
|
|
35
36
|
}
|
|
36
37
|
function withVisuallyHiddenLabel(Component) {
|
|
37
|
-
|
|
38
|
+
function WrappedComponent(props) {
|
|
38
39
|
const [label, labelProps, labelRef] = (0, FieldContext_1.useFieldWrappedByInputLabel)();
|
|
39
|
-
const mergedRef = (0, fuselage_hooks_1.useMergedRefs)(ref, labelRef);
|
|
40
|
+
const mergedRef = (0, fuselage_hooks_1.useMergedRefs)(props.ref, labelRef);
|
|
40
41
|
return ((0, jsx_runtime_1.jsx)(Component, { ...props, ...labelProps, ref: mergedRef, labelChildren: (0, jsx_runtime_1.jsx)(react_aria_1.VisuallyHidden, { children: label }) }));
|
|
41
|
-
}
|
|
42
|
+
}
|
|
42
43
|
WrappedComponent.displayName = `withVisuallyHiddenLabel(${Component.displayName ?? Component.name ?? 'InputComponent'})`;
|
|
43
44
|
return WrappedComponent;
|
|
44
45
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"withLabelHelpers.js","sourceRoot":"","sources":["../../../src/Inputs/withLabelHelpers.tsx"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"withLabelHelpers.js","sourceRoot":"","sources":["../../../src/Inputs/withLabelHelpers.tsx"],"names":[],"mappings":";;AAkFE,kCAAW;AACX,gDAAkB;AAClB,0DAAuB;AACvB,0DAAuB;;AArFzB,+DAA+D;AAC/D,wCAAwC;AACxC,gEAA4D;AAE5D,2CAA4C;AAE5C,wDAK+B;AAI/B,SAAS,WAAW,CAClB,SAAoE;IAEpE,SAAS,gBAAgB,CAAC,KAAmC;QAC3D,MAAM,UAAU,GAAG,IAAA,wCAAyB,GAAE,CAAC;QAC/C,OAAO,uBAAC,SAAS,OAAK,KAAK,KAAM,UAAU,GAAI,CAAC;IAClD,CAAC;IAED,gBAAgB,CAAC,WAAW,GAAG,eAAe,SAAS,CAAC,WAAW,IAAI,SAAS,CAAC,IAAI,IAAI,gBAAgB,GAAG,CAAC;IAE7G,OAAO,gBAAgB,CAAC;AAC1B,CAAC;AAID,SAAS,kBAAkB,CACzB,SAAuE;IAEvE,SAAS,gBAAgB,CAAC,KAAmC;QAC3D,MAAM,UAAU,GAAG,IAAA,wCAAyB,GAAE,CAAC;QAC/C,OAAO,uBAAC,SAAS,OAAK,KAAK,KAAM,UAAU,GAAI,CAAC;IAClD,CAAC;IAED,gBAAgB,CAAC,WAAW,GAAG,sBAAsB,SAAS,CAAC,WAAW,IAAI,SAAS,CAAC,IAAI,IAAI,gBAAgB,GAAG,CAAC;IAEpH,OAAO,gBAAgB,CAAC;AAC1B,CAAC;AAID,SAAS,uBAAuB,CAC9B,SAA4E;IAE5E,SAAS,gBAAgB,CAAC,KAAmC;QAC3D,MAAM,UAAU,GAAG,IAAA,8CAA+B,GAAE,CAAC;QACrD,OAAO,uBAAC,SAAS,OAAK,KAAK,KAAM,UAAU,GAAI,CAAC;IAClD,CAAC;IAED,gBAAgB,CAAC,WAAW,GAAG,2BAA2B,SAAS,CAAC,WAAW,IAAI,SAAS,CAAC,IAAI,IAAI,gBAAgB,GAAG,CAAC;IAEzH,OAAO,gBAAgB,CAAC;AAC1B,CAAC;AAID,SAAS,uBAAuB,CAC9B,SAA0E;IAE1E,SAAS,gBAAgB,CAAC,KAAmC;QAC3D,MAAM,CAAC,KAAK,EAAE,UAAU,EAAE,QAAQ,CAAC,GAAG,IAAA,0CAA2B,GAAE,CAAC;QACpE,MAAM,SAAS,GAAG,IAAA,8BAAa,EAAC,KAAK,CAAC,GAAG,EAAE,QAAqB,CAAC,CAAC;QAClE,OAAO,CACL,uBAAC,SAAS,OACJ,KAAK,KACL,UAAU,EACd,GAAG,EAAE,SAAS,EACd,aAAa,EAAE,uBAAC,2BAAc,cAAE,KAAK,GAAkB,GACvD,CACH,CAAC;IACJ,CAAC;IAED,gBAAgB,CAAC,WAAW,GAAG,2BAA2B,SAAS,CAAC,WAAW,IAAI,SAAS,CAAC,IAAI,IAAI,gBAAgB,GAAG,CAAC;IAEzH,OAAO,gBAAgB,CAAC;AAC1B,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Field as FieldComponent } from '@rocket.chat/fuselage';
|
|
2
2
|
import type { ComponentProps, ReactNode } from 'react';
|
|
3
|
-
type FieldProps = {
|
|
3
|
+
export type FieldProps = {
|
|
4
4
|
children: ReactNode;
|
|
5
5
|
} & ComponentProps<typeof FieldComponent>;
|
|
6
|
-
declare function Field({ children, ...props }: FieldProps): import("react
|
|
6
|
+
declare function Field({ children, ...props }: FieldProps): import("react").JSX.Element;
|
|
7
7
|
export default Field;
|
|
8
8
|
//# sourceMappingURL=Field.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Field.d.ts","sourceRoot":"","sources":["../../../src/Field/Field.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,IAAI,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAChE,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAIvD,
|
|
1
|
+
{"version":3,"file":"Field.d.ts","sourceRoot":"","sources":["../../../src/Field/Field.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,IAAI,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAChE,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAIvD,MAAM,MAAM,UAAU,GAAG;IAAE,QAAQ,EAAE,SAAS,CAAA;CAAE,GAAG,cAAc,CAC/D,OAAO,cAAc,CACtB,CAAC;AAEF,iBAAS,KAAK,CAAC,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAE,EAAE,UAAU,+BAMhD;AAED,eAAe,KAAK,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ReactNode, RefCallback } from 'react';
|
|
2
|
-
type FieldContextValue = {
|
|
2
|
+
export type FieldContextValue = {
|
|
3
3
|
setDescriptor: (type: LabelTypes, unregister?: boolean) => void;
|
|
4
4
|
setLabel: (label: ReactNode) => void;
|
|
5
5
|
descriptors: Set<LabelTypes>;
|
|
@@ -37,5 +37,4 @@ export declare const useFieldWrappedByInputLabel: () => [ReactNode, {
|
|
|
37
37
|
"id": string;
|
|
38
38
|
"aria-invalid": "true" | "false";
|
|
39
39
|
}, RefCallback<HTMLElement>];
|
|
40
|
-
export {};
|
|
41
40
|
//# sourceMappingURL=FieldContext.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldContext.d.ts","sourceRoot":"","sources":["../../../src/Field/FieldContext.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AASpD,
|
|
1
|
+
{"version":3,"file":"FieldContext.d.ts","sourceRoot":"","sources":["../../../src/Field/FieldContext.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AASpD,MAAM,MAAM,iBAAiB,GAAG;IAC9B,aAAa,EAAE,CAAC,IAAI,EAAE,UAAU,EAAE,UAAU,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC;IAChE,QAAQ,EAAE,CAAC,KAAK,EAAE,SAAS,KAAK,IAAI,CAAC;IACrC,WAAW,EAAE,GAAG,CAAC,UAAU,CAAC,CAAC;IAC7B,KAAK,EAAE,SAAS,GAAG,IAAI,CAAC;IACxB,EAAE,EAAE,MAAM,CAAC;IACX,SAAS,EAAE,SAAS,CAAC;IACrB,YAAY,EAAE,CAAC,SAAS,EAAE,SAAS,KAAK,IAAI,CAAC;IAC7C,UAAU,EAAE,MAAM,IAAI,CAAC;IACvB,QAAQ,EAAE,CAAC,EAAE,EAAE,MAAM,IAAI,KAAK,IAAI,CAAC;CACpC,CAAC;AAEF,eAAO,MAAM,YAAY,4CAUvB,CAAC;AAEH,MAAM,MAAM,UAAU,GAAG,MAAM,GAAG,aAAa,GAAG,OAAO,GAAG,aAAa,CAAC;AAE1E,MAAM,MAAM,SAAS,GACjB,gBAAgB,GAChB,mBAAmB,GACnB,mBAAmB,CAAC;AAoBxB,eAAO,MAAM,aAAa,QAAO,CAAC,WAAW,CAAC,WAAW,CAAC,EAAE,MAAM,CAsBjE,CAAC;AAEF,eAAO,MAAM,iBAAiB,iBAG7B,CAAC;AAEF,eAAO,MAAM,oBAAoB,GAAI,MAAM,UAAU,WASpD,CAAC;AA0BF,eAAO,MAAM,yBAAyB;oBARjB,MAAM,GAAG,OAAO;;;CAuBpC,CAAC;AAGF,eAAO,MAAM,yBAAyB;oBA1BjB,MAAM,GAAG,OAAO;;;CAyCpC,CAAC;AAGF,eAAO,MAAM,+BAA+B;oBA5CvB,MAAM,GAAG,OAAO;;;;CA4DpC,CAAC;AAGF,eAAO,MAAM,2BAA2B,QAAO,CAC7C,SAAS,EACT;IACE,kBAAkB,EAAE,MAAM,CAAC;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,cAAc,EAAE,MAAM,GAAG,OAAO,CAAC;CAClC,EACD,WAAW,CAAC,WAAW,CAAC,CAqCzB,CAAC"}
|
|
@@ -71,6 +71,7 @@ const getAriaInvalid = (descriptors) => {
|
|
|
71
71
|
}
|
|
72
72
|
return { 'aria-invalid': 'false' };
|
|
73
73
|
};
|
|
74
|
+
// Input has id and label is htmlFor
|
|
74
75
|
const useFieldReferencedByInput = () => {
|
|
75
76
|
const { id, descriptors, setFieldType } = (0, react_1.useContext)(exports.FieldContext);
|
|
76
77
|
(0, react_1.useEffect)(() => {
|
|
@@ -83,6 +84,7 @@ const useFieldReferencedByInput = () => {
|
|
|
83
84
|
}), [descriptors, id]);
|
|
84
85
|
};
|
|
85
86
|
exports.useFieldReferencedByInput = useFieldReferencedByInput;
|
|
87
|
+
// label has id and input is aria-labelledby
|
|
86
88
|
const useFieldReferencedByLabel = () => {
|
|
87
89
|
const { id, descriptors, setFieldType } = (0, react_1.useContext)(exports.FieldContext);
|
|
88
90
|
(0, react_1.useEffect)(() => {
|
|
@@ -95,6 +97,7 @@ const useFieldReferencedByLabel = () => {
|
|
|
95
97
|
}), [descriptors, id]);
|
|
96
98
|
};
|
|
97
99
|
exports.useFieldReferencedByLabel = useFieldReferencedByLabel;
|
|
100
|
+
// label has id and input is aria-labelledby + has id for aria-controls
|
|
98
101
|
const useFieldReferencedByLabelWithId = () => {
|
|
99
102
|
const { id, descriptors, setFieldType } = (0, react_1.useContext)(exports.FieldContext);
|
|
100
103
|
(0, react_1.useEffect)(() => {
|
|
@@ -108,6 +111,7 @@ const useFieldReferencedByLabelWithId = () => {
|
|
|
108
111
|
}), [descriptors, id]);
|
|
109
112
|
};
|
|
110
113
|
exports.useFieldReferencedByLabelWithId = useFieldReferencedByLabelWithId;
|
|
114
|
+
// label is rendered visually hidden inside the inputs wrapper label
|
|
111
115
|
const useFieldWrappedByInputLabel = () => {
|
|
112
116
|
const { id, label, descriptors, setFieldType, onAction } = (0, react_1.useContext)(exports.FieldContext);
|
|
113
117
|
(0, react_1.useEffect)(() => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldContext.js","sourceRoot":"","sources":["../../../src/Field/FieldContext.ts"],"names":[],"mappings":";;;AAAA,gEAAiE;AAEjE,iCAMe;AAcF,QAAA,YAAY,GAAG,IAAA,qBAAa,EAAoB;IAC3D,aAAa,EAAE,GAAG,EAAE,GAAE,CAAC;IACvB,QAAQ,EAAE,GAAG,EAAE,GAAE,CAAC;IAClB,WAAW,EAAE,IAAI,GAAG,EAAE;IACtB,KAAK,EAAE,IAAI;IACX,EAAE,EAAE,EAAE;IACN,SAAS,EAAE,mBAAmB;IAC9B,YAAY,EAAE,GAAG,EAAE,GAAE,CAAC;IACtB,UAAU,EAAE,GAAG,EAAE,GAAE,CAAC;IACpB,QAAQ,EAAE,GAAG,EAAE,GAAE,CAAC;CACnB,CAAC,CAAC;AASH,MAAM,eAAe,GAAG,CAAC,IAAiB,EAAE,EAAE;IAC5C,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC;QACtB,OAAO,IAAI,CAAC;IACd,CAAC;IAED,MAAM,IAAI,GAAG,EAAE,CAAC;IAChB,MAAM,UAAU,GAAG,IAAI,CAAC,aAAa,CAAC,gBAAgB,CACpD,IAAI,EACJ,UAAU,CAAC,SAAS,CACrB,CAAC;IAEF,OAAO,UAAU,CAAC,QAAQ,EAAE,EAAE,C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AM,2BAA2B,GAAG,GAQzC,EAAE;IACF,MAAM,EAAE,EAAE,EAAE,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,QAAQ,EAAE,GACtD,IAAA,kBAAU,EAAC,oBAAY,CAAC,CAAC;IAE3B,IAAA,iBAAS,EAAC,GAAG,EAAE;QACb,YAAY,CAAC,gBAAgB,CAAC,CAAC;IACjC,CAAC,EAAE,CAAC,YAAY,CAAC,CAAC,CAAC;IAEnB,MAAM,WAAW,GAAG,IAAA,mCAAkB,EACpC,IAAA,mBAAW,EACT,CAAC,IAAiB,EAAE,EAAE;QACpB,IAAI,CAAC,IAAI,EAAE,CAAC;YACV,OAAO;QACT,CAAC;QAED,QAAQ,CAAC,GAAG,EAAE;YACZ,IAAI,CAAC,KAAK,EAAE,CAAC;YACb,IAAI,CAAC,KAAK,EAAE,CAAC;QACf,CAAC,CAAC,CAAC;IACL,CAAC,EACD,CAAC,QAAQ,CAAC,CACX,CACF,CAAC;IAEF,OAAO,IAAA,eAAO,EACZ,GAAG,EAAE,CAAC;QACJ,KAAK;QACL;YACE,kBAAkB,EAAE,cAAc,CAAC,WAAW,EAAE,EAAE,CAAC;YACnD,IAAI,EAAE,UAAU,CAAC,EAAE,EAAE,WAAW,CAAC;YACjC,GAAG,cAAc,CAAC,WAAW,CAAC;SAC/B;QACD,WAAW;KACZ,EACD,CAAC,KAAK,EAAE,WAAW,EAAE,EAAE,EAAE,WAAW,CAAC,CACtC,CAAC;AACJ,CAAC,CAAC;AA5CW,QAAA,2BAA2B,+BA4CtC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { FieldDescription as FieldDescriptionComponent } from '@rocket.chat/fuselage';
|
|
2
2
|
import type { ReactNode, ComponentProps } from 'react';
|
|
3
|
-
type FieldDescriptionProps = {
|
|
3
|
+
export type FieldDescriptionProps = {
|
|
4
4
|
children: ReactNode;
|
|
5
5
|
} & ComponentProps<typeof FieldDescriptionComponent>;
|
|
6
|
-
declare const FieldDescription: ({ children, ...props }: FieldDescriptionProps) => import("react
|
|
6
|
+
declare const FieldDescription: ({ children, ...props }: FieldDescriptionProps) => import("react").JSX.Element;
|
|
7
7
|
export default FieldDescription;
|
|
8
8
|
//# sourceMappingURL=FieldDescription.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldDescription.d.ts","sourceRoot":"","sources":["../../../src/Field/FieldDescription.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,IAAI,yBAAyB,EAAE,MAAM,uBAAuB,CAAC;AACtF,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAIvD,
|
|
1
|
+
{"version":3,"file":"FieldDescription.d.ts","sourceRoot":"","sources":["../../../src/Field/FieldDescription.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,IAAI,yBAAyB,EAAE,MAAM,uBAAuB,CAAC;AACtF,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAIvD,MAAM,MAAM,qBAAqB,GAAG;IAAE,QAAQ,EAAE,SAAS,CAAA;CAAE,GAAG,cAAc,CAC1E,OAAO,yBAAyB,CACjC,CAAC;AAEF,QAAA,MAAM,gBAAgB,GAAI,wBAAwB,qBAAqB,gCAQtE,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { FieldError as FieldErrorComponent } from '@rocket.chat/fuselage';
|
|
2
2
|
import type { ReactNode, ComponentProps } from 'react';
|
|
3
|
-
type FieldErrorProps = {
|
|
3
|
+
export type FieldErrorProps = {
|
|
4
4
|
children: ReactNode;
|
|
5
5
|
} & ComponentProps<typeof FieldErrorComponent>;
|
|
6
|
-
declare const FieldError: ({ children, ...props }: FieldErrorProps) => import("react
|
|
6
|
+
declare const FieldError: ({ children, ...props }: FieldErrorProps) => import("react").JSX.Element;
|
|
7
7
|
export default FieldError;
|
|
8
8
|
//# sourceMappingURL=FieldError.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldError.d.ts","sourceRoot":"","sources":["../../../src/Field/FieldError.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC1E,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAIvD,
|
|
1
|
+
{"version":3,"file":"FieldError.d.ts","sourceRoot":"","sources":["../../../src/Field/FieldError.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC1E,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAIvD,MAAM,MAAM,eAAe,GAAG;IAAE,QAAQ,EAAE,SAAS,CAAA;CAAE,GAAG,cAAc,CACpE,OAAO,mBAAmB,CAC3B,CAAC;AAEF,QAAA,MAAM,UAAU,GAAI,wBAAwB,eAAe,gCAO1D,CAAC;AAEF,eAAe,UAAU,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { FieldHint as FieldHintComponent } from '@rocket.chat/fuselage';
|
|
2
2
|
import type { ReactNode, ComponentProps } from 'react';
|
|
3
|
-
type FieldHintProps = {
|
|
3
|
+
export type FieldHintProps = {
|
|
4
4
|
children: ReactNode;
|
|
5
5
|
} & ComponentProps<typeof FieldHintComponent>;
|
|
6
|
-
declare const FieldHint: ({ children, ...props }: FieldHintProps) => import("react
|
|
6
|
+
declare const FieldHint: ({ children, ...props }: FieldHintProps) => import("react").JSX.Element;
|
|
7
7
|
export default FieldHint;
|
|
8
8
|
//# sourceMappingURL=FieldHint.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldHint.d.ts","sourceRoot":"","sources":["../../../src/Field/FieldHint.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,IAAI,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AACxE,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAIvD,
|
|
1
|
+
{"version":3,"file":"FieldHint.d.ts","sourceRoot":"","sources":["../../../src/Field/FieldHint.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,IAAI,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AACxE,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAIvD,MAAM,MAAM,cAAc,GAAG;IAAE,QAAQ,EAAE,SAAS,CAAA;CAAE,GAAG,cAAc,CACnE,OAAO,kBAAkB,CAC1B,CAAC;AAEF,QAAA,MAAM,SAAS,GAAI,wBAAwB,cAAc,gCAQxD,CAAC;AAEF,eAAe,SAAS,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { ReactNode } from 'react';
|
|
2
|
-
type FieldProviderProps = {
|
|
2
|
+
export type FieldProviderProps = {
|
|
3
3
|
children: ReactNode;
|
|
4
4
|
};
|
|
5
|
-
declare function FieldProvider({ children }: FieldProviderProps): import("react
|
|
5
|
+
declare function FieldProvider({ children }: FieldProviderProps): import("react").JSX.Element;
|
|
6
6
|
export default FieldProvider;
|
|
7
7
|
//# sourceMappingURL=FieldProvider.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldProvider.d.ts","sourceRoot":"","sources":["../../../src/Field/FieldProvider.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAOvC,
|
|
1
|
+
{"version":3,"file":"FieldProvider.d.ts","sourceRoot":"","sources":["../../../src/Field/FieldProvider.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAOvC,MAAM,MAAM,kBAAkB,GAAG;IAAE,QAAQ,EAAE,SAAS,CAAA;CAAE,CAAC;AAEzD,iBAAS,aAAa,CAAC,EAAE,QAAQ,EAAE,EAAE,kBAAkB,+BAoDtD;AAED,eAAe,aAAa,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { FieldLabel as FieldLabelComponent } from '@rocket.chat/fuselage';
|
|
2
2
|
import { type ComponentPropsWithoutRef } from 'react';
|
|
3
|
-
type FieldLabelProps = ComponentPropsWithoutRef<typeof FieldLabelComponent>;
|
|
4
|
-
declare const FieldLabel: (props: FieldLabelProps) => import("react
|
|
3
|
+
export type FieldLabelProps = ComponentPropsWithoutRef<typeof FieldLabelComponent>;
|
|
4
|
+
declare const FieldLabel: (props: FieldLabelProps) => import("react").JSX.Element;
|
|
5
5
|
export default FieldLabel;
|
|
6
6
|
//# sourceMappingURL=FieldLabel.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldLabel.d.ts","sourceRoot":"","sources":["../../../../src/Field/Label/FieldLabel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC/E,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,OAAO,CAAC;AAQtD,
|
|
1
|
+
{"version":3,"file":"FieldLabel.d.ts","sourceRoot":"","sources":["../../../../src/Field/Label/FieldLabel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC/E,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,OAAO,CAAC;AAQtD,MAAM,MAAM,eAAe,GAAG,wBAAwB,CACpD,OAAO,mBAAmB,CAC3B,CAAC;AAEF,QAAA,MAAM,UAAU,GAAI,OAAO,eAAe,gCAWzC,CAAC;AAEF,eAAe,UAAU,CAAC"}
|
|
@@ -16,6 +16,7 @@ const FieldLabel = (props) => {
|
|
|
16
16
|
if (fieldType === 'referencedByInput') {
|
|
17
17
|
return (0, jsx_runtime_1.jsx)(ReferencedLabel_1.default, { ...props });
|
|
18
18
|
}
|
|
19
|
+
// referencedByLabel
|
|
19
20
|
return (0, jsx_runtime_1.jsx)(LabelFor_1.default, { ...props });
|
|
20
21
|
};
|
|
21
22
|
exports.default = FieldLabel;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldLabel.js","sourceRoot":"","sources":["../../../../src/Field/Label/FieldLabel.tsx"],"names":[],"mappings":";;;;;;AAGA,kDAAoD;AAEpD,gEAAwC;AACxC,0DAAkC;AAClC,wEAAgD;
|
|
1
|
+
{"version":3,"file":"FieldLabel.js","sourceRoot":"","sources":["../../../../src/Field/Label/FieldLabel.tsx"],"names":[],"mappings":";;;;;;AAGA,kDAAoD;AAEpD,gEAAwC;AACxC,0DAAkC;AAClC,wEAAgD;AAMhD,MAAM,UAAU,GAAG,CAAC,KAAsB,EAAE,EAAE;IAC5C,MAAM,SAAS,GAAG,IAAA,gCAAiB,GAAE,CAAC;IAEtC,IAAI,SAAS,KAAK,gBAAgB,EAAE,CAAC;QACnC,OAAO,uBAAC,qBAAW,OAAK,KAAK,GAAI,CAAC;IACpC,CAAC;IACD,IAAI,SAAS,KAAK,mBAAmB,EAAE,CAAC;QACtC,OAAO,uBAAC,yBAAe,OAAK,KAAK,GAAI,CAAC;IACxC,CAAC;IACD,oBAAoB;IACpB,OAAO,uBAAC,kBAAQ,OAAK,KAAK,GAAI,CAAC;AACjC,CAAC,CAAC;AAEF,kBAAe,UAAU,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FieldLabel as FieldLabelComponent } from '@rocket.chat/fuselage';
|
|
2
2
|
import type { ComponentProps } from 'react';
|
|
3
|
-
type HiddenLabelProps = ComponentProps<typeof FieldLabelComponent>;
|
|
4
|
-
declare const HiddenLabel: ({ children, ...props }: HiddenLabelProps) => import("react
|
|
3
|
+
export type HiddenLabelProps = ComponentProps<typeof FieldLabelComponent>;
|
|
4
|
+
declare const HiddenLabel: ({ children, ...props }: HiddenLabelProps) => import("react").JSX.Element;
|
|
5
5
|
export default HiddenLabel;
|
|
6
6
|
//# sourceMappingURL=HiddenLabel.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HiddenLabel.d.ts","sourceRoot":"","sources":["../../../../src/Field/Label/HiddenLabel.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC1E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAI5C,
|
|
1
|
+
{"version":3,"file":"HiddenLabel.d.ts","sourceRoot":"","sources":["../../../../src/Field/Label/HiddenLabel.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC1E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAI5C,MAAM,MAAM,gBAAgB,GAAG,cAAc,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAE1E,QAAA,MAAM,WAAW,GAAI,wBAAwB,gBAAgB,gCAQ5D,CAAC;AAEF,eAAe,WAAW,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FieldLabel as FieldLabelComponent } from '@rocket.chat/fuselage';
|
|
2
2
|
import type { ComponentProps } from 'react';
|
|
3
|
-
type LabelForProps = ComponentProps<typeof FieldLabelComponent>;
|
|
4
|
-
declare const LabelFor: ({ children, ...props }: LabelForProps) => import("react
|
|
3
|
+
export type LabelForProps = ComponentProps<typeof FieldLabelComponent>;
|
|
4
|
+
declare const LabelFor: ({ children, ...props }: LabelForProps) => import("react").JSX.Element;
|
|
5
5
|
export default LabelFor;
|
|
6
6
|
//# sourceMappingURL=LabelFor.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LabelFor.d.ts","sourceRoot":"","sources":["../../../../src/Field/Label/LabelFor.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC1E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAI5C,
|
|
1
|
+
{"version":3,"file":"LabelFor.d.ts","sourceRoot":"","sources":["../../../../src/Field/Label/LabelFor.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC1E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAI5C,MAAM,MAAM,aAAa,GAAG,cAAc,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEvE,QAAA,MAAM,QAAQ,GAAI,wBAAwB,aAAa,gCAOtD,CAAC;AAEF,eAAe,QAAQ,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FieldLabel as FieldLabelComponent } from '@rocket.chat/fuselage';
|
|
2
2
|
import type { ComponentProps } from 'react';
|
|
3
|
-
type ReferencedLabelProps = ComponentProps<typeof FieldLabelComponent>;
|
|
4
|
-
declare const ReferencedLabel: ({ children, ...props }: ReferencedLabelProps) => import("react
|
|
3
|
+
export type ReferencedLabelProps = ComponentProps<typeof FieldLabelComponent>;
|
|
4
|
+
declare const ReferencedLabel: ({ children, ...props }: ReferencedLabelProps) => import("react").JSX.Element;
|
|
5
5
|
export default ReferencedLabel;
|
|
6
6
|
//# sourceMappingURL=ReferencedLabel.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ReferencedLabel.d.ts","sourceRoot":"","sources":["../../../../src/Field/Label/ReferencedLabel.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC1E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAI5C,
|
|
1
|
+
{"version":3,"file":"ReferencedLabel.d.ts","sourceRoot":"","sources":["../../../../src/Field/Label/ReferencedLabel.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC1E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAI5C,MAAM,MAAM,oBAAoB,GAAG,cAAc,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAE9E,QAAA,MAAM,eAAe,GAAI,wBAAwB,oBAAoB,gCAQpE,CAAC;AAEF,eAAe,eAAe,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { default as LabelFor } from './LabelFor';
|
|
2
|
-
export { default as HiddenLabel } from './HiddenLabel';
|
|
3
|
-
export { default as ReferencedLabel } from './ReferencedLabel';
|
|
4
|
-
export { default as FieldLabel } from './FieldLabel';
|
|
1
|
+
export { default as LabelFor, type LabelForProps } from './LabelFor';
|
|
2
|
+
export { default as HiddenLabel, type HiddenLabelProps } from './HiddenLabel';
|
|
3
|
+
export { default as ReferencedLabel, type ReferencedLabelProps, } from './ReferencedLabel';
|
|
4
|
+
export { default as FieldLabel, type FieldLabelProps } from './FieldLabel';
|
|
5
5
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/Field/Label/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/Field/Label/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,KAAK,aAAa,EAAE,MAAM,YAAY,CAAC;AACrE,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,KAAK,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAC9E,OAAO,EACL,OAAO,IAAI,eAAe,EAC1B,KAAK,oBAAoB,GAC1B,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,KAAK,eAAe,EAAE,MAAM,cAAc,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/Field/Label/index.ts"],"names":[],"mappings":";;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/Field/Label/index.ts"],"names":[],"mappings":";;;;;;AAAA,uCAAqE;AAA5D,qHAAA,OAAO,OAAY;AAC5B,6CAA8E;AAArE,2HAAA,OAAO,OAAe;AAC/B,qDAG2B;AAFzB,mIAAA,OAAO,OAAmB;AAG5B,2CAA2E;AAAlE,yHAAA,OAAO,OAAc"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export { default as Field } from './Field';
|
|
2
|
-
export { default as FieldProvider } from './FieldProvider';
|
|
3
|
-
export { default as FieldDescription } from './FieldDescription';
|
|
4
|
-
export { default as FieldError } from './FieldError';
|
|
5
|
-
export { default as FieldHint } from './FieldHint';
|
|
1
|
+
export { default as Field, type FieldProps } from './Field';
|
|
2
|
+
export { default as FieldProvider, type FieldProviderProps, } from './FieldProvider';
|
|
3
|
+
export { default as FieldDescription, type FieldDescriptionProps, } from './FieldDescription';
|
|
4
|
+
export { default as FieldError, type FieldErrorProps } from './FieldError';
|
|
5
|
+
export { default as FieldHint, type FieldHintProps } from './FieldHint';
|
|
6
6
|
export * from './FieldContext';
|
|
7
7
|
export * from './Label';
|
|
8
8
|
export { FieldGroup, FieldRow, FieldLink, FieldLabelInfo, } from '@rocket.chat/fuselage';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/Field/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/Field/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,KAAK,UAAU,EAAE,MAAM,SAAS,CAAC;AAC5D,OAAO,EACL,OAAO,IAAI,aAAa,EACxB,KAAK,kBAAkB,GACxB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,OAAO,IAAI,gBAAgB,EAC3B,KAAK,qBAAqB,GAC3B,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,KAAK,eAAe,EAAE,MAAM,cAAc,CAAC;AAC3E,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,KAAK,cAAc,EAAE,MAAM,aAAa,CAAC;AAExE,cAAc,gBAAgB,CAAC;AAE/B,cAAc,SAAS,CAAC;AAExB,OAAO,EACL,UAAU,EACV,QAAQ,EACR,SAAS,EACT,cAAc,GACf,MAAM,uBAAuB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/Field/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/Field/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,iCAA4D;AAAnD,+GAAA,OAAO,OAAS;AACzB,iDAGyB;AAFvB,+HAAA,OAAO,OAAiB;AAG1B,uDAG4B;AAF1B,qIAAA,OAAO,OAAoB;AAG7B,2CAA2E;AAAlE,yHAAA,OAAO,OAAc;AAC9B,yCAAwE;AAA/D,uHAAA,OAAO,OAAa;AAE7B,iDAA+B;AAE/B,0CAAwB;AAExB,kDAK+B;AAJ7B,sGAAA,UAAU,OAAA;AACV,oGAAA,QAAQ,OAAA;AACR,qGAAA,SAAS,OAAA;AACT,0GAAA,cAAc,OAAA"}
|