@rocket.chat/fuselage 0.32.0-dev.69 → 0.32.0-dev.71
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/components/Button/IconButton.d.ts.map +1 -1
- package/dist/components/Options/Options.d.ts +2 -1
- package/dist/components/Options/Options.d.ts.map +1 -1
- package/dist/components/Options/useCursor.d.ts +1 -1
- package/dist/components/Options/useCursor.d.ts.map +1 -1
- package/dist/fuselage.development.js +3 -3
- package/dist/fuselage.development.js.map +1 -1
- package/dist/fuselage.production.js +1 -1
- package/package.json +11 -11
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IconButton.d.ts","sourceRoot":"","sources":["../../../src/components/Button/IconButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAO,MAAM,OAAO,CAAC;AAC5D,OAAO,KAA8B,MAAM,OAAO,CAAC;AAGnD,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAE/B,aAAK,UAAU,GAAG;IAChB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,CAAC;AAgBF,eAAO,MAAM,UAAU;;;;;;;UAbb,eAAe,WAAW,CAAC,CAAC,MAAM,CAAC;eAC9B,SAAS;;;;;;;
|
|
1
|
+
{"version":3,"file":"IconButton.d.ts","sourceRoot":"","sources":["../../../src/components/Button/IconButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAO,MAAM,OAAO,CAAC;AAC5D,OAAO,KAA8B,MAAM,OAAO,CAAC;AAGnD,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAE/B,aAAK,UAAU,GAAG;IAChB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,CAAC;AAgBF,eAAO,MAAM,UAAU;;;;;;;UAbb,eAAe,WAAW,CAAC,CAAC,MAAM,CAAC;eAC9B,SAAS;;;;;;;mqSAuEvB,CAAC"}
|
|
@@ -6,7 +6,8 @@ export declare type OptionType = [
|
|
|
6
6
|
value: string | number,
|
|
7
7
|
label: ReactNode,
|
|
8
8
|
selected?: boolean,
|
|
9
|
-
type?: 'heading' | 'divider' | 'option'
|
|
9
|
+
type?: 'heading' | 'divider' | 'option',
|
|
10
|
+
url?: string
|
|
10
11
|
];
|
|
11
12
|
export declare const Empty: React.MemoExoticComponent<({ customEmpty }: {
|
|
12
13
|
customEmpty: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Options.d.ts","sourceRoot":"","sources":["../../../src/components/Options/Options.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAEV,WAAW,EACX,SAAS,EAGV,MAAM,OAAO,CAAC;AACf,OAAO,KAMN,MAAM,OAAO,CAAC;AAMf,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAExC,OAAO,EAAE,SAAS,EAAE,CAAC;AAOrB,oBAAY,UAAU,GAAG;IACvB,KAAK,EAAE,MAAM,GAAG,MAAM;IACtB,KAAK,EAAE,SAAS;IAChB,QAAQ,CAAC,EAAE,OAAO;IAClB,IAAI,CAAC,EAAE,SAAS,GAAG,SAAS,GAAG,QAAQ;
|
|
1
|
+
{"version":3,"file":"Options.d.ts","sourceRoot":"","sources":["../../../src/components/Options/Options.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAEV,WAAW,EACX,SAAS,EAGV,MAAM,OAAO,CAAC;AACf,OAAO,KAMN,MAAM,OAAO,CAAC;AAMf,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAExC,OAAO,EAAE,SAAS,EAAE,CAAC;AAOrB,oBAAY,UAAU,GAAG;IACvB,KAAK,EAAE,MAAM,GAAG,MAAM;IACtB,KAAK,EAAE,SAAS;IAChB,QAAQ,CAAC,EAAE,OAAO;IAClB,IAAI,CAAC,EAAE,SAAS,GAAG,SAAS,GAAG,QAAQ;IACvC,GAAG,CAAC,EAAE,MAAM;CACb,CAAC;AAYF,eAAO,MAAM,KAAK;iBAAyC,MAAM;kBAE/D,CAAC;AAEH,eAAO,MAAM,OAAO;;;;;;;;aAZT,UAAU,EAAE;YACb,MAAM;;;sCAGoB,IAAI;;4nSAoGvC,CAAC"}
|
|
@@ -2,5 +2,5 @@ import type { KeyboardEvent } from 'react';
|
|
|
2
2
|
import type { OptionType } from './Options';
|
|
3
3
|
import { useVisible } from './useVisible';
|
|
4
4
|
export declare type UseCursorOnChange<T> = (option: T, visibilityHandler: ReturnType<typeof useVisible>) => void;
|
|
5
|
-
export declare const useCursor: <T extends readonly [value: unknown, label: unknown, selected?: unknown, type?: "option" | "heading" | "divider" | undefined] = OptionType>(initial: number, options: T[], onChange: UseCursorOnChange<T>) => [cursor: number, handleKeyDown: (e: KeyboardEvent) => void, handleKeyUp: (e: KeyboardEvent) => void, reset: () => void, visibilityHandler: [visible: import("../AnimatedVisibility/AnimatedVisibility").VisibilityType, hide: () => void, show: () => void]];
|
|
5
|
+
export declare const useCursor: <T extends readonly [value: unknown, label: unknown, selected?: unknown, type?: "option" | "heading" | "divider" | undefined, url?: string | undefined] = OptionType>(initial: number, options: T[], onChange: UseCursorOnChange<T>) => [cursor: number, handleKeyDown: (e: KeyboardEvent) => void, handleKeyUp: (e: KeyboardEvent) => void, reset: () => void, visibilityHandler: [visible: import("../AnimatedVisibility/AnimatedVisibility").VisibilityType, hide: () => void, show: () => void]];
|
|
6
6
|
//# sourceMappingURL=useCursor.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useCursor.d.ts","sourceRoot":"","sources":["../../../src/components/Options/useCursor.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAI3C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAqD1C,oBAAY,iBAAiB,CAAC,CAAC,IAAI,CACjC,MAAM,EAAE,CAAC,EACT,iBAAiB,EAAE,UAAU,CAAC,OAAO,UAAU,CAAC,KAC7C,IAAI,CAAC;AAEV,eAAO,MAAM,SAAS,
|
|
1
|
+
{"version":3,"file":"useCursor.d.ts","sourceRoot":"","sources":["../../../src/components/Options/useCursor.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAI3C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAqD1C,oBAAY,iBAAiB,CAAC,CAAC,IAAI,CACjC,MAAM,EAAE,CAAC,EACT,iBAAiB,EAAE,UAAU,CAAC,OAAO,UAAU,CAAC,KAC7C,IAAI,CAAC;AAEV,eAAO,MAAM,SAAS,iLASX,MAAM,uFAKI,aAAa,KAAK,IAAI,mBACxB,aAAa,KAAK,IAAI,eAC1B,IAAI,sIA4FlB,CAAC"}
|
|
@@ -5951,7 +5951,7 @@ var IconButton = (0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)(function (_a,
|
|
|
5951
5951
|
}
|
|
5952
5952
|
return {};
|
|
5953
5953
|
}, [primary, info, secondary, danger, warning, success]);
|
|
5954
|
-
return (react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_Box__WEBPACK_IMPORTED_MODULE_1__["default"], __assign({ is: 'button', "rcx-button": true, "rcx-button--icon": true, "rcx-button--square": square }, kindAndVariantProps, { "rcx-button--small-square": small, "rcx-button--tiny-square": tiny, "rcx-button--mini-square": mini, ref: ref }, props),
|
|
5954
|
+
return (react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_Box__WEBPACK_IMPORTED_MODULE_1__["default"], __assign({ is: 'button', type: 'button', "rcx-button": true, "rcx-button--icon": true, "rcx-button--square": square }, kindAndVariantProps, { "rcx-button--small-square": small, "rcx-button--tiny-square": tiny, "rcx-button--mini-square": mini, ref: ref }, props),
|
|
5955
5955
|
children,
|
|
5956
5956
|
react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_Icon__WEBPACK_IMPORTED_MODULE_2__.Icon, { name: icon, size: getSize({ mini: mini }) })));
|
|
5957
5957
|
});
|
|
@@ -11640,7 +11640,7 @@ var Options = (0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)(function (_a, re
|
|
|
11640
11640
|
}, [cursor]);
|
|
11641
11641
|
var optionsMemoized = (0,react__WEBPACK_IMPORTED_MODULE_0__.useMemo)(function () {
|
|
11642
11642
|
return options === null || options === void 0 ? void 0 : options.map(function (_a, i) {
|
|
11643
|
-
var _b = __read(_a,
|
|
11643
|
+
var _b = __read(_a, 5), value = _b[0], label = _b[1], selected = _b[2], type = _b[3], url = _b[4];
|
|
11644
11644
|
switch (type) {
|
|
11645
11645
|
case 'heading':
|
|
11646
11646
|
return react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_Option__WEBPACK_IMPORTED_MODULE_4__.OptionHeader, { key: value }, label);
|
|
@@ -11649,7 +11649,7 @@ var Options = (0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)(function (_a, re
|
|
|
11649
11649
|
default:
|
|
11650
11650
|
return (react__WEBPACK_IMPORTED_MODULE_0___default().createElement(OptionComponent, { role: 'option', label: label, onMouseDown: function (e) {
|
|
11651
11651
|
prevent(e);
|
|
11652
|
-
onSelect([value, label]);
|
|
11652
|
+
onSelect([value, label, selected, type, url]);
|
|
11653
11653
|
return false;
|
|
11654
11654
|
}, key: value, value: value, selected: selected || (multiple !== true && null), focus: cursor === i || null }));
|
|
11655
11655
|
}
|