@rocket.chat/fuselage-forms 1.0.0 → 1.1.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.
@@ -1,3 +1,4 @@
1
+ import { Slider as SliderComponent } from '@rocket.chat/fuselage';
1
2
  export declare const TextInput: {
2
3
  (props: Omit<import("@rocket.chat/fuselage").InputBoxProps, "type"> & {
3
4
  addon?: import("react").ReactNode;
@@ -57,6 +58,25 @@ export declare const Select: {
57
58
  } & Omit<import("react").AllHTMLAttributes<HTMLElement>, "value" | "onChange"> & import("react").RefAttributes<HTMLElement>): import("react/jsx-runtime").JSX.Element;
58
59
  displayName: string;
59
60
  };
61
+ export declare const MultiSelect: {
62
+ (props: Omit<import("@rocket.chat/fuselage").BoxProps, "value" | "onChange"> & {
63
+ value?: import("@rocket.chat/fuselage").SelectOption[0][];
64
+ error?: string;
65
+ options: import("@rocket.chat/fuselage").SelectOption[];
66
+ onChange: (params: import("@rocket.chat/fuselage").SelectOption[0][]) => void;
67
+ getLabel?: (params: import("@rocket.chat/fuselage").SelectOption) => import("@rocket.chat/fuselage").SelectOption[1];
68
+ getValue?: (params: import("@rocket.chat/fuselage").SelectOption) => import("@rocket.chat/fuselage").SelectOption[0];
69
+ customEmpty?: string;
70
+ anchor?: import("react").ElementType<import("@rocket.chat/fuselage/dist/components/MultiSelect/MultiSelectAnchorParams").MultiSelectAnchorParams> | ((params: import("@rocket.chat/fuselage/dist/components/MultiSelect/MultiSelectAnchorParams").MultiSelectAnchorParams) => import("react").ReactNode);
71
+ renderOptions?: import("react").ElementType;
72
+ renderItem?: import("react").ElementType;
73
+ renderSelected?: import("react").ElementType;
74
+ addonIcon?: import("@rocket.chat/fuselage").IconProps["name"];
75
+ setFilter?: (filter: string) => void;
76
+ } & import("react").RefAttributes<HTMLInputElement>): import("react/jsx-runtime").JSX.Element;
77
+ displayName: string;
78
+ };
79
+ export declare const Slider: typeof SliderComponent;
60
80
  export declare const CheckBox: {
61
81
  (props: import("@rocket.chat/fuselage").BoxProps & {
62
82
  indeterminate?: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"WrappedInputComponents.d.ts","sourceRoot":"","sources":["../../../src/Inputs/WrappedInputComponents.ts"],"names":[],"mappings":"AAwBA,eAAO,MAAM,SAAS;;;;;;CAAkC,CAAC;AACzD,eAAO,MAAM,UAAU;;;;;;CAAmC,CAAC;AAC3D,eAAO,MAAM,aAAa;;;CAAsC,CAAC;AACjE,eAAO,MAAM,WAAW;;;;;;CAAoC,CAAC;AAC7D,eAAO,MAAM,aAAa;;;;;;CAAiC,CAAC;AAC5D,eAAO,MAAM,cAAc;;;;;;;CAAuC,CAAC;AACnE,eAAO,MAAM,WAAW;;;CAAoC,CAAC;AAC7D,eAAO,MAAM,QAAQ;;;CAAiC,CAAC;AAGvD,eAAO,MAAM,MAAM;;;;;;;;;;CAAsC,CAAC;AAG1D,eAAO,MAAM,QAAQ;;;;;;CAA6C,CAAC;AACnE,eAAO,MAAM,YAAY;;;;;CAAiD,CAAC;AAC3E,eAAO,MAAM,WAAW;;;;;CAAgD,CAAC"}
1
+ {"version":3,"file":"WrappedInputComponents.d.ts","sourceRoot":"","sources":["../../../src/Inputs/WrappedInputComponents.ts"],"names":[],"mappings":"AAAA,OAAO,EAcL,MAAM,IAAI,eAAe,EAC1B,MAAM,uBAAuB,CAAC;AAW/B,eAAO,MAAM,SAAS;;;;;;CAAkC,CAAC;AACzD,eAAO,MAAM,UAAU;;;;;;CAAmC,CAAC;AAC3D,eAAO,MAAM,aAAa;;;CAAsC,CAAC;AACjE,eAAO,MAAM,WAAW;;;;;;CAAoC,CAAC;AAC7D,eAAO,MAAM,aAAa;;;;;;CAAiC,CAAC;AAC5D,eAAO,MAAM,cAAc;;;;;;;CAAuC,CAAC;AACnE,eAAO,MAAM,WAAW;;;CAAoC,CAAC;AAC7D,eAAO,MAAM,QAAQ;;;CAAiC,CAAC;AAGvD,eAAO,MAAM,MAAM;;;;;;;;;;CAAsC,CAAC;AAC1D,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;CAA2C,CAAC;AACpE,eAAO,MAAM,MAAM,EAEd,OAAO,eAAe,CAAC;AAG5B,eAAO,MAAM,QAAQ;;;;;;CAA6C,CAAC;AACnE,eAAO,MAAM,YAAY;;;;;CAAiD,CAAC;AAC3E,eAAO,MAAM,WAAW;;;;;CAAgD,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.RadioButton = exports.ToggleSwitch = exports.CheckBox = exports.Select = exports.UrlInput = exports.NumberInput = exports.TelephoneInput = exports.TextAreaInput = exports.SearchInput = exports.PasswordInput = exports.EmailInput = exports.TextInput = void 0;
3
+ exports.RadioButton = exports.ToggleSwitch = exports.CheckBox = exports.Slider = exports.MultiSelect = exports.Select = exports.UrlInput = exports.NumberInput = exports.TelephoneInput = exports.TextAreaInput = exports.SearchInput = exports.PasswordInput = exports.EmailInput = exports.TextInput = void 0;
4
4
  const fuselage_1 = require("@rocket.chat/fuselage");
5
5
  const withLabelHelpers_1 = require("./withLabelHelpers");
6
6
  exports.TextInput = (0, withLabelHelpers_1.withLabelId)(fuselage_1.TextInput);
@@ -12,6 +12,8 @@ exports.TelephoneInput = (0, withLabelHelpers_1.withLabelId)(fuselage_1.Telephon
12
12
  exports.NumberInput = (0, withLabelHelpers_1.withLabelId)(fuselage_1.NumberInput);
13
13
  exports.UrlInput = (0, withLabelHelpers_1.withLabelId)(fuselage_1.UrlInput);
14
14
  exports.Select = (0, withLabelHelpers_1.withAriaLabelledBy)(fuselage_1.Select);
15
+ exports.MultiSelect = (0, withLabelHelpers_1.withAriaLabelledBy)(fuselage_1.MultiSelect);
16
+ exports.Slider = (0, withLabelHelpers_1.withAriaLabelledBy)(fuselage_1.Slider);
15
17
  exports.CheckBox = (0, withLabelHelpers_1.withVisuallyHiddenLabel)(fuselage_1.CheckBox);
16
18
  exports.ToggleSwitch = (0, withLabelHelpers_1.withVisuallyHiddenLabel)(fuselage_1.ToggleSwitch);
17
19
  exports.RadioButton = (0, withLabelHelpers_1.withVisuallyHiddenLabel)(fuselage_1.RadioButton);
@@ -1 +1 @@
1
- {"version":3,"file":"WrappedInputComponents.js","sourceRoot":"","sources":["../../../src/Inputs/WrappedInputComponents.ts"],"names":[],"mappings":";;;AAAA,oDAa+B;AAE/B,yDAI4B;AAKf,QAAA,SAAS,GAAG,IAAA,8BAAW,EAAC,oBAAkB,CAAC,CAAC;AAC5C,QAAA,UAAU,GAAG,IAAA,8BAAW,EAAC,qBAAmB,CAAC,CAAC;AAC9C,QAAA,aAAa,GAAG,IAAA,8BAAW,EAAC,wBAAsB,CAAC,CAAC;AACpD,QAAA,WAAW,GAAG,IAAA,8BAAW,EAAC,sBAAoB,CAAC,CAAC;AAChD,QAAA,aAAa,GAAG,IAAA,8BAAW,EAAC,wBAAiB,CAAC,CAAC;AAC/C,QAAA,cAAc,GAAG,IAAA,8BAAW,EAAC,yBAAuB,CAAC,CAAC;AACtD,QAAA,WAAW,GAAG,IAAA,8BAAW,EAAC,sBAAoB,CAAC,CAAC;AAChD,QAAA,QAAQ,GAAG,IAAA,8BAAW,EAAC,mBAAiB,CAAC,CAAC;AAG1C,QAAA,MAAM,GAAG,IAAA,qCAAkB,EAAC,iBAAe,CAAC,CAAC;AAG7C,QAAA,QAAQ,GAAG,IAAA,0CAAuB,EAAC,mBAAiB,CAAC,CAAC;AACtD,QAAA,YAAY,GAAG,IAAA,0CAAuB,EAAC,uBAAqB,CAAC,CAAC;AAC9D,QAAA,WAAW,GAAG,IAAA,0CAAuB,EAAC,sBAAoB,CAAC,CAAC"}
1
+ {"version":3,"file":"WrappedInputComponents.js","sourceRoot":"","sources":["../../../src/Inputs/WrappedInputComponents.ts"],"names":[],"mappings":";;;AAAA,oDAe+B;AAE/B,yDAI4B;AAKf,QAAA,SAAS,GAAG,IAAA,8BAAW,EAAC,oBAAkB,CAAC,CAAC;AAC5C,QAAA,UAAU,GAAG,IAAA,8BAAW,EAAC,qBAAmB,CAAC,CAAC;AAC9C,QAAA,aAAa,GAAG,IAAA,8BAAW,EAAC,wBAAsB,CAAC,CAAC;AACpD,QAAA,WAAW,GAAG,IAAA,8BAAW,EAAC,sBAAoB,CAAC,CAAC;AAChD,QAAA,aAAa,GAAG,IAAA,8BAAW,EAAC,wBAAiB,CAAC,CAAC;AAC/C,QAAA,cAAc,GAAG,IAAA,8BAAW,EAAC,yBAAuB,CAAC,CAAC;AACtD,QAAA,WAAW,GAAG,IAAA,8BAAW,EAAC,sBAAoB,CAAC,CAAC;AAChD,QAAA,QAAQ,GAAG,IAAA,8BAAW,EAAC,mBAAiB,CAAC,CAAC;AAG1C,QAAA,MAAM,GAAG,IAAA,qCAAkB,EAAC,iBAAe,CAAC,CAAC;AAC7C,QAAA,WAAW,GAAG,IAAA,qCAAkB,EAAC,sBAAoB,CAAC,CAAC;AACvD,QAAA,MAAM,GAAG,IAAA,qCAAkB,EACtC,iBAAe,CACU,CAAC;AAGf,QAAA,QAAQ,GAAG,IAAA,0CAAuB,EAAC,mBAAiB,CAAC,CAAC;AACtD,QAAA,YAAY,GAAG,IAAA,0CAAuB,EAAC,uBAAqB,CAAC,CAAC;AAC9D,QAAA,WAAW,GAAG,IAAA,0CAAuB,EAAC,sBAAoB,CAAC,CAAC"}
@@ -1,3 +1,4 @@
1
+ import { Slider as SliderComponent } from '@rocket.chat/fuselage';
1
2
  export declare const TextInput: {
2
3
  (props: Omit<import("@rocket.chat/fuselage").InputBoxProps, "type"> & {
3
4
  addon?: import("react").ReactNode;
@@ -57,6 +58,25 @@ export declare const Select: {
57
58
  } & Omit<import("react").AllHTMLAttributes<HTMLElement>, "value" | "onChange"> & import("react").RefAttributes<HTMLElement>): import("react/jsx-runtime").JSX.Element;
58
59
  displayName: string;
59
60
  };
61
+ export declare const MultiSelect: {
62
+ (props: Omit<import("@rocket.chat/fuselage").BoxProps, "value" | "onChange"> & {
63
+ value?: import("@rocket.chat/fuselage").SelectOption[0][];
64
+ error?: string;
65
+ options: import("@rocket.chat/fuselage").SelectOption[];
66
+ onChange: (params: import("@rocket.chat/fuselage").SelectOption[0][]) => void;
67
+ getLabel?: (params: import("@rocket.chat/fuselage").SelectOption) => import("@rocket.chat/fuselage").SelectOption[1];
68
+ getValue?: (params: import("@rocket.chat/fuselage").SelectOption) => import("@rocket.chat/fuselage").SelectOption[0];
69
+ customEmpty?: string;
70
+ anchor?: import("react").ElementType<import("@rocket.chat/fuselage/dist/components/MultiSelect/MultiSelectAnchorParams").MultiSelectAnchorParams> | ((params: import("@rocket.chat/fuselage/dist/components/MultiSelect/MultiSelectAnchorParams").MultiSelectAnchorParams) => import("react").ReactNode);
71
+ renderOptions?: import("react").ElementType;
72
+ renderItem?: import("react").ElementType;
73
+ renderSelected?: import("react").ElementType;
74
+ addonIcon?: import("@rocket.chat/fuselage").IconProps["name"];
75
+ setFilter?: (filter: string) => void;
76
+ } & import("react").RefAttributes<HTMLInputElement>): import("react/jsx-runtime").JSX.Element;
77
+ displayName: string;
78
+ };
79
+ export declare const Slider: typeof SliderComponent;
60
80
  export declare const CheckBox: {
61
81
  (props: import("@rocket.chat/fuselage").BoxProps & {
62
82
  indeterminate?: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"WrappedInputComponents.d.ts","sourceRoot":"","sources":["../../../src/Inputs/WrappedInputComponents.ts"],"names":[],"mappings":"AAwBA,eAAO,MAAM,SAAS;;;;;;CAAkC,CAAC;AACzD,eAAO,MAAM,UAAU;;;;;;CAAmC,CAAC;AAC3D,eAAO,MAAM,aAAa;;;CAAsC,CAAC;AACjE,eAAO,MAAM,WAAW;;;;;;CAAoC,CAAC;AAC7D,eAAO,MAAM,aAAa;;;;;;CAAiC,CAAC;AAC5D,eAAO,MAAM,cAAc;;;;;;;CAAuC,CAAC;AACnE,eAAO,MAAM,WAAW;;;CAAoC,CAAC;AAC7D,eAAO,MAAM,QAAQ;;;CAAiC,CAAC;AAGvD,eAAO,MAAM,MAAM;;;;;;;;;;CAAsC,CAAC;AAG1D,eAAO,MAAM,QAAQ;;;;;;CAA6C,CAAC;AACnE,eAAO,MAAM,YAAY;;;;;CAAiD,CAAC;AAC3E,eAAO,MAAM,WAAW;;;;;CAAgD,CAAC"}
1
+ {"version":3,"file":"WrappedInputComponents.d.ts","sourceRoot":"","sources":["../../../src/Inputs/WrappedInputComponents.ts"],"names":[],"mappings":"AAAA,OAAO,EAcL,MAAM,IAAI,eAAe,EAC1B,MAAM,uBAAuB,CAAC;AAW/B,eAAO,MAAM,SAAS;;;;;;CAAkC,CAAC;AACzD,eAAO,MAAM,UAAU;;;;;;CAAmC,CAAC;AAC3D,eAAO,MAAM,aAAa;;;CAAsC,CAAC;AACjE,eAAO,MAAM,WAAW;;;;;;CAAoC,CAAC;AAC7D,eAAO,MAAM,aAAa;;;;;;CAAiC,CAAC;AAC5D,eAAO,MAAM,cAAc;;;;;;;CAAuC,CAAC;AACnE,eAAO,MAAM,WAAW;;;CAAoC,CAAC;AAC7D,eAAO,MAAM,QAAQ;;;CAAiC,CAAC;AAGvD,eAAO,MAAM,MAAM;;;;;;;;;;CAAsC,CAAC;AAC1D,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;CAA2C,CAAC;AACpE,eAAO,MAAM,MAAM,EAEd,OAAO,eAAe,CAAC;AAG5B,eAAO,MAAM,QAAQ;;;;;;CAA6C,CAAC;AACnE,eAAO,MAAM,YAAY;;;;;CAAiD,CAAC;AAC3E,eAAO,MAAM,WAAW;;;;;CAAgD,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.RadioButton = exports.ToggleSwitch = exports.CheckBox = exports.Select = exports.UrlInput = exports.NumberInput = exports.TelephoneInput = exports.TextAreaInput = exports.SearchInput = exports.PasswordInput = exports.EmailInput = exports.TextInput = void 0;
3
+ exports.RadioButton = exports.ToggleSwitch = exports.CheckBox = exports.Slider = exports.MultiSelect = exports.Select = exports.UrlInput = exports.NumberInput = exports.TelephoneInput = exports.TextAreaInput = exports.SearchInput = exports.PasswordInput = exports.EmailInput = exports.TextInput = void 0;
4
4
  const fuselage_1 = require("@rocket.chat/fuselage");
5
5
  const withLabelHelpers_1 = require("./withLabelHelpers");
6
6
  exports.TextInput = (0, withLabelHelpers_1.withLabelId)(fuselage_1.TextInput);
@@ -12,6 +12,8 @@ exports.TelephoneInput = (0, withLabelHelpers_1.withLabelId)(fuselage_1.Telephon
12
12
  exports.NumberInput = (0, withLabelHelpers_1.withLabelId)(fuselage_1.NumberInput);
13
13
  exports.UrlInput = (0, withLabelHelpers_1.withLabelId)(fuselage_1.UrlInput);
14
14
  exports.Select = (0, withLabelHelpers_1.withAriaLabelledBy)(fuselage_1.Select);
15
+ exports.MultiSelect = (0, withLabelHelpers_1.withAriaLabelledBy)(fuselage_1.MultiSelect);
16
+ exports.Slider = (0, withLabelHelpers_1.withAriaLabelledBy)(fuselage_1.Slider);
15
17
  exports.CheckBox = (0, withLabelHelpers_1.withVisuallyHiddenLabel)(fuselage_1.CheckBox);
16
18
  exports.ToggleSwitch = (0, withLabelHelpers_1.withVisuallyHiddenLabel)(fuselage_1.ToggleSwitch);
17
19
  exports.RadioButton = (0, withLabelHelpers_1.withVisuallyHiddenLabel)(fuselage_1.RadioButton);
@@ -1 +1 @@
1
- {"version":3,"file":"WrappedInputComponents.js","sourceRoot":"","sources":["../../../src/Inputs/WrappedInputComponents.ts"],"names":[],"mappings":";;;AAAA,oDAa+B;AAE/B,yDAI4B;AAKf,QAAA,SAAS,GAAG,IAAA,8BAAW,EAAC,oBAAkB,CAAC,CAAC;AAC5C,QAAA,UAAU,GAAG,IAAA,8BAAW,EAAC,qBAAmB,CAAC,CAAC;AAC9C,QAAA,aAAa,GAAG,IAAA,8BAAW,EAAC,wBAAsB,CAAC,CAAC;AACpD,QAAA,WAAW,GAAG,IAAA,8BAAW,EAAC,sBAAoB,CAAC,CAAC;AAChD,QAAA,aAAa,GAAG,IAAA,8BAAW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C,sBAAoB,CAAC,CAAC;AACvD,QAAA,MAAM,GAAG,IAAA,qCAAkB,EACtC,iBAAe,CACU,CAAC;AAGf,QAAA,QAAQ,GAAG,IAAA,0CAAuB,EAAC,mBAAiB,CAAC,CAAC;AACtD,QAAA,YAAY,GAAG,IAAA,0CAAuB,EAAC,uBAAqB,CAAC,CAAC;AAC9D,QAAA,WAAW,GAAG,IAAA,0CAAuB,EAAC,sBAAoB,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rocket.chat/fuselage-forms",
3
- "version": "1.0.0",
3
+ "version": "1.1.0",
4
4
  "description": "A set of component wrappers to provide ease of use and accessibility out-of-box.",
5
5
  "homepage": "https://github.com/RocketChat/fuselage#readme",
6
6
  "bugs": {
@@ -35,7 +35,8 @@
35
35
  "test": "jest --runInBand"
36
36
  },
37
37
  "devDependencies": {
38
- "@rocket.chat/fuselage": "*",
38
+ "@rocket.chat/fuselage": "^0.74.0",
39
+ "@rocket.chat/fuselage-hooks": "^0.41.0",
39
40
  "@rocket.chat/fuselage-tokens": "^0.33.2",
40
41
  "@rocket.chat/storybook-dark-mode": "^4.1.0",
41
42
  "@storybook/addon-docs": "~9.1.17",
@@ -58,14 +59,14 @@
58
59
  "react": "~18.3.1",
59
60
  "react-dom": "~18.3.1",
60
61
  "rimraf": "~6.0.1",
61
- "storybook": "~9.1.17",
62
+ "storybook": "~9.1.19",
62
63
  "ts-jest": "~29.4.6",
63
64
  "typescript": "~5.9.3",
64
65
  "webpack": "~5.102.1"
65
66
  },
66
67
  "peerDependencies": {
67
68
  "@rocket.chat/fuselage": "*",
68
- "@rocket.chat/fuselage-hooks": "^0.39.0",
69
+ "@rocket.chat/fuselage-hooks": "*",
69
70
  "react": "*",
70
71
  "react-dom": "*"
71
72
  },