@koobiq/react-components 0.11.1 → 0.13.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/components/Button/Button.js +1 -1
- package/dist/components/Checkbox/Checkbox.d.ts +1 -1
- package/dist/components/Collections/Column.d.ts +1 -1
- package/dist/components/Container/Container.js +13 -4
- package/dist/components/Container/types.d.ts +18 -3
- package/dist/components/Container/types.js +3 -1
- package/dist/components/DateInput/DateInput.js +36 -32
- package/dist/components/DateInput/DateInput.module.css.js +4 -1
- package/dist/components/DateInput/types.d.ts +10 -12
- package/dist/components/DateInput/types.js +5 -5
- package/dist/components/DatePicker/DatePicker.js +18 -2
- package/dist/components/DatePicker/types.d.ts +2 -2
- package/dist/components/Dialog/Dialog.js +2 -2
- package/dist/components/Dialog/components/DialogCloseButton.d.ts +2 -2
- package/dist/components/Form/Form.d.ts +9 -13
- package/dist/components/Form/Form.js +29 -32
- package/dist/components/Form/Form.module.css.js +19 -7
- package/dist/components/Form/FormContext.d.ts +5 -3
- package/dist/components/Form/components/FormActions/FormActions.d.ts +7 -0
- package/dist/components/Form/components/FormActions/FormActions.js +9 -0
- package/dist/components/Form/components/FormActions/index.d.ts +1 -0
- package/dist/components/Form/components/FormCaption/FormCaption.d.ts +16 -0
- package/dist/components/Form/components/FormCaption/FormCaption.js +17 -0
- package/dist/components/Form/components/FormCaption/index.d.ts +1 -0
- package/dist/components/Form/components/FormGroup/FormGroup.d.ts +7 -0
- package/dist/components/Form/components/FormGroup/FormGroup.js +9 -0
- package/dist/components/Form/components/FormGroup/index.d.ts +1 -0
- package/dist/components/Form/components/index.d.ts +3 -0
- package/dist/components/Form/types.d.ts +7 -3
- package/dist/components/Form/utils.js +12 -12
- package/dist/components/FormField/FormField.d.ts +22 -0
- package/dist/components/FormField/FormField.js +55 -0
- package/dist/components/FormField/FormField.module.css.js +17 -0
- package/dist/components/FormField/FormFieldAddon/FormFieldAddon.d.ts +10 -0
- package/dist/components/{FieldComponents/FieldAddon/FieldAddon.js → FormField/FormFieldAddon/FormFieldAddon.js} +9 -14
- package/dist/components/FormField/FormFieldAddon/FormFieldAddon.module.css.js +20 -0
- package/dist/components/FormField/FormFieldAddon/index.d.ts +1 -0
- package/dist/components/{FieldComponents/FieldCaption/FieldCaption.d.ts → FormField/FormFieldCaption/FormFieldCaption.d.ts} +3 -3
- package/dist/components/{FieldComponents/FieldCaption/FieldCaption.js → FormField/FormFieldCaption/FormFieldCaption.js} +4 -4
- package/dist/components/{FieldComponents/FieldError/FieldError.module.css.js → FormField/FormFieldCaption/FormFieldCaption.module.css.js} +1 -1
- package/dist/components/FormField/FormFieldCaption/index.d.ts +1 -0
- package/dist/components/FormField/FormFieldControlGroup/FormFieldControlGroup.d.ts +2 -0
- package/dist/components/{FieldComponents/FieldContentGroup/FieldContentGroup.js → FormField/FormFieldControlGroup/FormFieldControlGroup.js} +11 -29
- package/dist/components/FormField/FormFieldControlGroup/FormFieldControlGroup.module.css.js +23 -0
- package/dist/components/FormField/FormFieldControlGroup/FormFieldControlGroupContext.d.ts +10 -0
- package/dist/components/FormField/FormFieldControlGroup/FormFieldControlGroupContext.js +7 -0
- package/dist/components/FormField/FormFieldControlGroup/index.d.ts +3 -0
- package/dist/components/FormField/FormFieldControlGroup/types.d.ts +30 -0
- package/dist/components/FormField/FormFieldControlGroup/types.js +7 -0
- package/dist/components/FormField/FormFieldError/FormFieldError.d.ts +8 -0
- package/dist/components/FormField/FormFieldError/FormFieldError.js +17 -0
- package/dist/components/{FieldComponents/FieldCaption/FieldCaption.module.css.js → FormField/FormFieldError/FormFieldError.module.css.js} +1 -1
- package/dist/components/FormField/FormFieldError/index.d.ts +1 -0
- package/dist/components/FormField/FormFieldInput/FormFieldInput.d.ts +8 -0
- package/dist/components/FormField/FormFieldInput/FormFieldInput.js +12 -0
- package/dist/components/{FieldComponents/Field/Field.module.css.js → FormField/FormFieldInput/FormFieldInput.module.css.js} +1 -1
- package/dist/components/FormField/FormFieldInput/index.d.ts +1 -0
- package/dist/components/FormField/FormFieldInputDate/FormFieldInputDate.d.ts +8 -0
- package/dist/components/FormField/FormFieldInputDate/FormFieldInputDate.js +9 -0
- package/dist/components/FormField/FormFieldInputDate/FormFieldInputDate.module.css.js +8 -0
- package/dist/components/FormField/FormFieldInputDate/index.d.ts +1 -0
- package/dist/components/FormField/FormFieldLabel/FormFieldLabel.d.ts +4 -0
- package/dist/components/{FormControlLabel/FormControlLabel.js → FormField/FormFieldLabel/FormFieldLabel.js} +5 -4
- package/dist/components/FormField/FormFieldLabel/FormFieldLabel.module.css.js +14 -0
- package/dist/components/FormField/FormFieldLabel/index.d.ts +2 -0
- package/dist/components/{FormControlLabel → FormField/FormFieldLabel}/types.d.ts +1 -1
- package/dist/components/FormField/FormFieldSelect/FormFieldSelect.d.ts +4 -0
- package/dist/components/FormField/FormFieldSelect/FormFieldSelect.js +33 -0
- package/dist/components/FormField/FormFieldSelect/FormFieldSelect.module.css.js +20 -0
- package/dist/components/FormField/FormFieldSelect/index.d.ts +2 -0
- package/dist/components/FormField/FormFieldSelect/types.d.ts +7 -0
- package/dist/components/FormField/index.d.ts +9 -0
- package/dist/components/FormField/types.d.ts +19 -0
- package/dist/components/FormField/types.js +6 -0
- package/dist/components/Input/Input.d.ts +8 -10
- package/dist/components/Input/Input.js +22 -23
- package/dist/components/Input/Input.module.css.js +5 -1
- package/dist/components/Input/types.d.ts +10 -12
- package/dist/components/Input/types.js +5 -5
- package/dist/components/InputNumber/InputNumber.d.ts +8 -10
- package/dist/components/InputNumber/InputNumber.js +22 -22
- package/dist/components/InputNumber/InputNumber.module.css.js +8 -0
- package/dist/components/InputNumber/components/InputNumberCounterControls.js +2 -2
- package/dist/components/InputNumber/types.d.ts +10 -12
- package/dist/components/InputNumber/types.js +5 -5
- package/dist/components/List/components/ListSection/ListSection.js +1 -1
- package/dist/components/RadioGroup/RadioGroup.js +14 -13
- package/dist/components/RadioGroup/RadioGroup.module.css.js +4 -1
- package/dist/components/RadioGroup/components/Radio/Radio.d.ts +1 -1
- package/dist/components/RadioGroup/types.d.ts +7 -9
- package/dist/components/RadioGroup/types.js +3 -3
- package/dist/components/SearchInput/SearchInput.d.ts +8 -10
- package/dist/components/SearchInput/SearchInput.js +39 -30
- package/dist/components/SearchInput/SearchInput.module.css.js +4 -1
- package/dist/components/SearchInput/types.d.ts +10 -12
- package/dist/components/SearchInput/types.js +5 -5
- package/dist/components/Select/Select.js +36 -27
- package/dist/components/Select/Select.module.css.js +4 -4
- package/dist/components/Select/components/TagGroup/TagGroupMultiline.js +2 -2
- package/dist/components/Select/components/TagGroup/TagGroupResponsive.js +2 -2
- package/dist/components/Select/types.d.ts +8 -10
- package/dist/components/Select/types.js +3 -3
- package/dist/components/Table/Table.js +7 -5
- package/dist/components/Table/components/TableColumnHeader/TableColumnHeader.d.ts +3 -1
- package/dist/components/Table/components/TableColumnHeader/TableColumnHeader.js +21 -3
- package/dist/components/Table/components/TableColumnHeader/TableColumnHeader.module.css.js +13 -1
- package/dist/components/Table/components/TableRowGroup/TableRowGroup.d.ts +3 -1
- package/dist/components/Table/components/TableRowGroup/TableRowGroup.js +7 -2
- package/dist/components/Table/types.d.ts +11 -2
- package/dist/components/Textarea/Textarea.d.ts +5 -5
- package/dist/components/Textarea/Textarea.js +6 -4
- package/dist/components/Textarea/Textarea.module.css.js +8 -2
- package/dist/components/Textarea/components/TextareaContextConsumer/TextareaContextConsumer.d.ts +1 -1
- package/dist/components/Textarea/components/TextareaContextConsumer/TextareaContextConsumer.js +24 -20
- package/dist/components/Textarea/types.d.ts +8 -10
- package/dist/components/Textarea/types.js +5 -5
- package/dist/components/TimePicker/TimePicker.js +37 -31
- package/dist/components/TimePicker/TimePicker.module.css.js +4 -1
- package/dist/components/TimePicker/types.d.ts +9 -11
- package/dist/components/TimePicker/types.js +3 -3
- package/dist/components/Toggle/Toggle.d.ts +1 -1
- package/dist/components/Tooltip/Tooltip.d.ts +1 -1
- package/dist/components/index.d.ts +3 -4
- package/dist/index.js +30 -13
- package/dist/style.css +469 -386
- package/dist/types.d.ts +0 -1
- package/package.json +5 -5
- package/dist/components/FieldComponents/Field/Field.d.ts +0 -4
- package/dist/components/FieldComponents/Field/Field.js +0 -10
- package/dist/components/FieldComponents/Field/index.d.ts +0 -2
- package/dist/components/FieldComponents/Field/types.d.ts +0 -4
- package/dist/components/FieldComponents/FieldAddon/FieldAddon.d.ts +0 -11
- package/dist/components/FieldComponents/FieldAddon/FieldAddon.module.css.js +0 -20
- package/dist/components/FieldComponents/FieldAddon/index.d.ts +0 -1
- package/dist/components/FieldComponents/FieldCaption/index.d.ts +0 -1
- package/dist/components/FieldComponents/FieldContentGroup/FieldContentGroup.d.ts +0 -2
- package/dist/components/FieldComponents/FieldContentGroup/FieldContentGroup.module.css.js +0 -29
- package/dist/components/FieldComponents/FieldContentGroup/FieldContentGroupContext.d.ts +0 -10
- package/dist/components/FieldComponents/FieldContentGroup/FieldContentGroupContext.js +0 -7
- package/dist/components/FieldComponents/FieldContentGroup/index.d.ts +0 -3
- package/dist/components/FieldComponents/FieldContentGroup/types.d.ts +0 -29
- package/dist/components/FieldComponents/FieldContentGroup/types.js +0 -4
- package/dist/components/FieldComponents/FieldError/FieldError.d.ts +0 -8
- package/dist/components/FieldComponents/FieldError/FieldError.js +0 -19
- package/dist/components/FieldComponents/FieldError/index.d.ts +0 -1
- package/dist/components/FieldComponents/FieldInput/FieldInput.d.ts +0 -12
- package/dist/components/FieldComponents/FieldInput/FieldInput.js +0 -34
- package/dist/components/FieldComponents/FieldInput/FieldInput.module.css.js +0 -20
- package/dist/components/FieldComponents/FieldInput/index.d.ts +0 -1
- package/dist/components/FieldComponents/FieldInputDate/FieldInputDate.d.ts +0 -12
- package/dist/components/FieldComponents/FieldInputDate/FieldInputDate.js +0 -32
- package/dist/components/FieldComponents/FieldInputDate/FieldInputDate.module.css.js +0 -20
- package/dist/components/FieldComponents/FieldInputDate/index.d.ts +0 -1
- package/dist/components/FieldComponents/FieldSelect/FieldSelect.d.ts +0 -4
- package/dist/components/FieldComponents/FieldSelect/FieldSelect.js +0 -45
- package/dist/components/FieldComponents/FieldSelect/FieldSelect.module.css.js +0 -26
- package/dist/components/FieldComponents/FieldSelect/index.d.ts +0 -2
- package/dist/components/FieldComponents/FieldSelect/types.d.ts +0 -11
- package/dist/components/FieldComponents/index.d.ts +0 -8
- package/dist/components/FormControl/FormControl.d.ts +0 -4
- package/dist/components/FormControl/FormControl.js +0 -41
- package/dist/components/FormControl/FormControl.module.css.js +0 -17
- package/dist/components/FormControl/index.d.ts +0 -2
- package/dist/components/FormControl/types.d.ts +0 -19
- package/dist/components/FormControl/types.js +0 -6
- package/dist/components/FormControlLabel/FormControlLabel.d.ts +0 -4
- package/dist/components/FormControlLabel/FormControlLabel.module.css.js +0 -14
- package/dist/components/FormControlLabel/index.d.ts +0 -2
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { useRef } from "react";
|
|
4
4
|
import { useFocusRing, mergeProps, clsx } from "@koobiq/react-core";
|
|
5
|
+
import { IconChevronUpS16, IconChevronDownS16 } from "@koobiq/react-icons";
|
|
5
6
|
import { useTableColumnHeader } from "@koobiq/react-primitives";
|
|
6
7
|
import { utilClasses } from "../../../../styles/utility.js";
|
|
7
8
|
import s from "./TableColumnHeader.module.css.js";
|
|
8
9
|
const textNormal = utilClasses.typography["text-normal"];
|
|
9
10
|
function TableColumnHeader({
|
|
10
11
|
column,
|
|
11
|
-
state
|
|
12
|
+
state,
|
|
13
|
+
renderSortIcon
|
|
12
14
|
}) {
|
|
13
15
|
const ref = useRef(null);
|
|
14
16
|
const { columnHeaderProps } = useTableColumnHeader(
|
|
@@ -23,6 +25,11 @@ function TableColumnHeader({
|
|
|
23
25
|
valign = "middle"
|
|
24
26
|
} = column.props;
|
|
25
27
|
const { isFocusVisible, focusProps } = useFocusRing();
|
|
28
|
+
const isActive = state.sortDescriptor?.column === column.key;
|
|
29
|
+
const { allowsSorting } = column.props;
|
|
30
|
+
const direction = isActive ? state.sortDescriptor?.direction : void 0;
|
|
31
|
+
const defaultIcon = direction === "ascending" ? /* @__PURE__ */ jsx(IconChevronUpS16, {}) : /* @__PURE__ */ jsx(IconChevronDownS16, {});
|
|
32
|
+
const iconToRender = renderSortIcon?.({ direction, isActive }) ?? defaultIcon;
|
|
26
33
|
return /* @__PURE__ */ jsx(
|
|
27
34
|
"th",
|
|
28
35
|
{
|
|
@@ -31,13 +38,24 @@ function TableColumnHeader({
|
|
|
31
38
|
s.base,
|
|
32
39
|
valign && s[valign],
|
|
33
40
|
isFocusVisible && s.focusVisible,
|
|
41
|
+
allowsSorting && s.sortable,
|
|
34
42
|
textNormal,
|
|
35
43
|
className
|
|
36
44
|
),
|
|
37
45
|
style,
|
|
38
46
|
...mergeProps(columnHeaderProps, focusProps),
|
|
39
47
|
ref,
|
|
40
|
-
children:
|
|
48
|
+
children: /* @__PURE__ */ jsxs("div", { className: s.content, children: [
|
|
49
|
+
/* @__PURE__ */ jsx("span", { children: column.rendered }),
|
|
50
|
+
allowsSorting && /* @__PURE__ */ jsx(
|
|
51
|
+
"span",
|
|
52
|
+
{
|
|
53
|
+
"aria-hidden": "true",
|
|
54
|
+
className: clsx(s.sortIcon, isActive && s.active),
|
|
55
|
+
children: iconToRender
|
|
56
|
+
}
|
|
57
|
+
)
|
|
58
|
+
] })
|
|
41
59
|
}
|
|
42
60
|
);
|
|
43
61
|
}
|
|
@@ -5,6 +5,10 @@ const middle = "kbq-tablecolumnheader-middle-22b85a";
|
|
|
5
5
|
const bottom = "kbq-tablecolumnheader-bottom-1f6f2d";
|
|
6
6
|
const sub = "kbq-tablecolumnheader-sub-c48ac7";
|
|
7
7
|
const focusVisible = "kbq-tablecolumnheader-focusVisible-21814b";
|
|
8
|
+
const sortable = "kbq-tablecolumnheader-sortable-038383";
|
|
9
|
+
const content = "kbq-tablecolumnheader-content-2b6a20";
|
|
10
|
+
const sortIcon = "kbq-tablecolumnheader-sortIcon-b98bf4";
|
|
11
|
+
const active = "kbq-tablecolumnheader-active-f9b640";
|
|
8
12
|
const s = {
|
|
9
13
|
base,
|
|
10
14
|
top,
|
|
@@ -13,15 +17,23 @@ const s = {
|
|
|
13
17
|
bottom,
|
|
14
18
|
sub,
|
|
15
19
|
"text-top": "kbq-tablecolumnheader-text-top-7013fa",
|
|
16
|
-
focusVisible
|
|
20
|
+
focusVisible,
|
|
21
|
+
sortable,
|
|
22
|
+
content,
|
|
23
|
+
sortIcon,
|
|
24
|
+
active
|
|
17
25
|
};
|
|
18
26
|
export {
|
|
27
|
+
active,
|
|
19
28
|
base,
|
|
20
29
|
baseline,
|
|
21
30
|
bottom,
|
|
31
|
+
content,
|
|
22
32
|
s as default,
|
|
23
33
|
focusVisible,
|
|
24
34
|
middle,
|
|
35
|
+
sortIcon,
|
|
36
|
+
sortable,
|
|
25
37
|
sub,
|
|
26
38
|
top
|
|
27
39
|
};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { ComponentPropsWithRef, ReactNode } from 'react';
|
|
2
2
|
export type TableRowGroupProps = {
|
|
3
3
|
children: ReactNode;
|
|
4
4
|
type: 'thead' | 'tbody';
|
|
5
|
+
theadProps?: ComponentPropsWithRef<'thead'>;
|
|
6
|
+
tbodyProps?: ComponentPropsWithRef<'tbody'>;
|
|
5
7
|
};
|
|
6
8
|
export declare const TableRowGroup: import("react").ForwardRefExoticComponent<TableRowGroupProps & import("react").RefAttributes<any>>;
|
|
@@ -1,12 +1,17 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
3
|
import { forwardRef } from "react";
|
|
4
|
+
import { mergeProps } from "@koobiq/react-core";
|
|
4
5
|
import { useTableRowGroup } from "@koobiq/react-primitives";
|
|
5
6
|
const TableRowGroup = forwardRef(
|
|
6
|
-
({ type = "thead", children }, ref) => {
|
|
7
|
+
({ type = "thead", children, theadProps, tbodyProps }, ref) => {
|
|
7
8
|
const Element = type;
|
|
8
9
|
const { rowGroupProps } = useTableRowGroup();
|
|
9
|
-
|
|
10
|
+
const elementProps = mergeProps(
|
|
11
|
+
{ ...rowGroupProps, ref },
|
|
12
|
+
type === "thead" ? theadProps : tbodyProps
|
|
13
|
+
);
|
|
14
|
+
return /* @__PURE__ */ jsx(Element, { ...elementProps, children });
|
|
10
15
|
}
|
|
11
16
|
);
|
|
12
17
|
TableRowGroup.displayName = "TableRowGroup";
|
|
@@ -1,10 +1,14 @@
|
|
|
1
|
-
import type { ComponentPropsWithRef, ComponentRef, CSSProperties, ReactElement, Ref } from 'react';
|
|
1
|
+
import type { ComponentPropsWithRef, ComponentRef, CSSProperties, ReactElement, ReactNode, Ref } from 'react';
|
|
2
2
|
import type { TableStateProps } from '@koobiq/react-primitives';
|
|
3
3
|
import type { Key } from '@react-types/shared';
|
|
4
4
|
export declare const tablePropDivider: readonly ["none", "row"];
|
|
5
5
|
export type TablePropDivider = (typeof tablePropDivider)[number];
|
|
6
6
|
export type TablePropChildren<T> = TableStateProps<T>['children'];
|
|
7
|
-
|
|
7
|
+
type TablePropSortIconRender = (args: {
|
|
8
|
+
direction: 'ascending' | 'descending' | undefined;
|
|
9
|
+
isActive: boolean;
|
|
10
|
+
}) => ReactNode;
|
|
11
|
+
export type TableProps<T> = Pick<TableStateProps<T>, 'selectionBehavior' | 'selectionMode' | 'selectedKeys' | 'defaultSelectedKeys' | 'onSelectionChange' | 'disabledKeys' | 'disabledBehavior' | 'sortDescriptor' | 'onSortChange'> & {
|
|
8
12
|
/** Handler that is called when a user performs an action on the row. */
|
|
9
13
|
onRowAction?: (key: Key) => void;
|
|
10
14
|
/** Handler that is called when a user performs an action on the cell. */
|
|
@@ -30,13 +34,18 @@ export type TableProps<T> = Pick<TableStateProps<T>, 'selectionBehavior' | 'sele
|
|
|
30
34
|
* The elements that make up the table.
|
|
31
35
|
* Includes the Table.Header, Table.Body, Table.Column, and Table.Row.
|
|
32
36
|
*/
|
|
37
|
+
/** Render function for a custom sort icon for the column */
|
|
38
|
+
renderSortIcon?: TablePropSortIconRender;
|
|
33
39
|
children?: TablePropChildren<T>;
|
|
34
40
|
/** Ref to the control. */
|
|
35
41
|
ref?: Ref<HTMLTableElement>;
|
|
36
42
|
/** The props used for each slot inside. */
|
|
37
43
|
slotProps?: {
|
|
38
44
|
root?: ComponentPropsWithRef<'table'>;
|
|
45
|
+
header?: ComponentPropsWithRef<'thead'>;
|
|
46
|
+
body?: ComponentPropsWithRef<'tbody'>;
|
|
39
47
|
};
|
|
40
48
|
};
|
|
41
49
|
export type TableComponent = <T>(props: TableProps<T>) => ReactElement | null;
|
|
42
50
|
export type TableRef = ComponentRef<'table'>;
|
|
51
|
+
export {};
|
|
@@ -4,7 +4,7 @@ export declare const Textarea: import("react").ForwardRefExoticComponent<Omit<{
|
|
|
4
4
|
required?: boolean;
|
|
5
5
|
hiddenLabel?: boolean;
|
|
6
6
|
readonly?: boolean;
|
|
7
|
-
} & Omit<import("@koobiq/react-primitives").TextFieldProps<HTMLTextAreaElement>, "children" | "style" | "className" | "
|
|
7
|
+
} & Omit<import("@koobiq/react-primitives").TextFieldProps<HTMLTextAreaElement>, "children" | "style" | "className" | "description" | "validationState" | "inputElementType">, "caption" | "style" | "className" | "cols" | "rows" | "data-testid" | "variant" | "slotProps" | "labelPlacement" | "labelAlign" | "fullWidth" | "isLabelHidden" | "expand"> & {
|
|
8
8
|
className?: string;
|
|
9
9
|
style?: import("react").CSSProperties;
|
|
10
10
|
variant?: import("./types").TextareaPropVariant;
|
|
@@ -18,9 +18,9 @@ export declare const Textarea: import("react").ForwardRefExoticComponent<Omit<{
|
|
|
18
18
|
expand?: import("./types").TextareaPropExpand;
|
|
19
19
|
'data-testid'?: string | number;
|
|
20
20
|
slotProps?: {
|
|
21
|
-
label?: import("..").
|
|
22
|
-
caption?: import("
|
|
23
|
-
textarea?: import("
|
|
24
|
-
errorMessage?: import("
|
|
21
|
+
label?: import("..").FormFieldLabelProps;
|
|
22
|
+
caption?: import("..").FormFieldCaptionProps;
|
|
23
|
+
textarea?: import("..").FormFieldInputProps<"textarea">;
|
|
24
|
+
errorMessage?: import("..").FormFieldErrorProps;
|
|
25
25
|
};
|
|
26
26
|
} & import("react").RefAttributes<HTMLTextAreaElement>>;
|
|
@@ -5,7 +5,8 @@ import { deprecate } from "@koobiq/logger";
|
|
|
5
5
|
import { mergeProps } from "@koobiq/react-core";
|
|
6
6
|
import { TextField } from "@koobiq/react-primitives";
|
|
7
7
|
import { TextareaContextConsumer } from "./components/TextareaContextConsumer/TextareaContextConsumer.js";
|
|
8
|
-
import {
|
|
8
|
+
import { useForm } from "../Form/FormContext.js";
|
|
9
|
+
import { FormField } from "../FormField/FormField.js";
|
|
9
10
|
const Textarea = forwardRef((props, ref) => {
|
|
10
11
|
const {
|
|
11
12
|
variant = "filled",
|
|
@@ -31,9 +32,10 @@ const Textarea = forwardRef((props, ref) => {
|
|
|
31
32
|
label,
|
|
32
33
|
...other
|
|
33
34
|
} = props;
|
|
34
|
-
const isDisabled
|
|
35
|
+
const { isDisabled: formIsDisabled, isReadOnly: formIsReadOnly } = useForm();
|
|
36
|
+
const isDisabled = isDisabledProp ?? disabled ?? formIsDisabled;
|
|
37
|
+
const isReadOnly = isReadOnlyProp ?? readonly ?? formIsReadOnly;
|
|
35
38
|
const isRequired = isRequiredProp ?? required;
|
|
36
|
-
const isReadOnly = isReadOnlyProp ?? readonly;
|
|
37
39
|
const isInvalid = isInvalidProp ?? error;
|
|
38
40
|
const isLabelHidden = isLabelHiddenProp ?? hiddenLabel;
|
|
39
41
|
if (process.env.NODE_ENV !== "production" && "disabled" in props) {
|
|
@@ -76,7 +78,7 @@ const Textarea = forwardRef((props, ref) => {
|
|
|
76
78
|
},
|
|
77
79
|
other
|
|
78
80
|
);
|
|
79
|
-
return /* @__PURE__ */ jsx(
|
|
81
|
+
return /* @__PURE__ */ jsx(FormField, { as: TextField, inputElementType: "textarea", ...rootProps, children: (values) => /* @__PURE__ */ jsx(
|
|
80
82
|
TextareaContextConsumer,
|
|
81
83
|
{
|
|
82
84
|
...values,
|
|
@@ -1,7 +1,13 @@
|
|
|
1
|
+
const body = "kbq-textarea-body-943a69";
|
|
2
|
+
const group = "kbq-textarea-group-c8f6ff";
|
|
1
3
|
const s = {
|
|
2
4
|
"auto-size": "kbq-textarea-auto-size-566580",
|
|
3
|
-
"vertical-resize": "kbq-textarea-vertical-resize-bde131"
|
|
5
|
+
"vertical-resize": "kbq-textarea-vertical-resize-bde131",
|
|
6
|
+
body,
|
|
7
|
+
group
|
|
4
8
|
};
|
|
5
9
|
export {
|
|
6
|
-
|
|
10
|
+
body,
|
|
11
|
+
s as default,
|
|
12
|
+
group
|
|
7
13
|
};
|
package/dist/components/Textarea/components/TextareaContextConsumer/TextareaContextConsumer.d.ts
CHANGED
|
@@ -3,4 +3,4 @@ export declare const TextareaContextConsumer: import("react").ForwardRefExoticCo
|
|
|
3
3
|
isRequired?: boolean;
|
|
4
4
|
isInvalid?: boolean;
|
|
5
5
|
isDisabled?: boolean;
|
|
6
|
-
} & Pick<TextareaProps, "caption" | "label" | "cols" | "rows" | "variant" | "
|
|
6
|
+
} & Pick<TextareaProps, "caption" | "label" | "cols" | "rows" | "variant" | "slotProps" | "labelPlacement" | "errorMessage" | "isLabelHidden" | "expand"> & import("react").RefAttributes<HTMLTextAreaElement>>;
|
package/dist/components/Textarea/components/TextareaContextConsumer/TextareaContextConsumer.js
CHANGED
|
@@ -4,12 +4,7 @@ import { useDOMRef, mergeProps } from "@koobiq/react-core";
|
|
|
4
4
|
import { useTextareaContext } from "@koobiq/react-primitives";
|
|
5
5
|
import s from "../../Textarea.module.css.js";
|
|
6
6
|
import { useTextareaAutosize } from "../../utils/useTextareaAutosize.js";
|
|
7
|
-
import {
|
|
8
|
-
import { Field } from "../../../FieldComponents/Field/Field.js";
|
|
9
|
-
import { FieldContentGroup } from "../../../FieldComponents/FieldContentGroup/FieldContentGroup.js";
|
|
10
|
-
import { FieldInput } from "../../../FieldComponents/FieldInput/FieldInput.js";
|
|
11
|
-
import { FieldCaption } from "../../../FieldComponents/FieldCaption/FieldCaption.js";
|
|
12
|
-
import { FieldError } from "../../../FieldComponents/FieldError/FieldError.js";
|
|
7
|
+
import { FormField } from "../../../FormField/FormField.js";
|
|
13
8
|
const TextareaContextConsumer = forwardRef((props, ref) => {
|
|
14
9
|
const {
|
|
15
10
|
rows,
|
|
@@ -26,38 +21,47 @@ const TextareaContextConsumer = forwardRef((props, ref) => {
|
|
|
26
21
|
errorMessage
|
|
27
22
|
} = props;
|
|
28
23
|
const { value } = useTextareaContext();
|
|
29
|
-
const
|
|
30
|
-
useTextareaAutosize(
|
|
24
|
+
const textareaRef = useDOMRef(ref);
|
|
25
|
+
useTextareaAutosize(textareaRef, value, expand === "auto-size");
|
|
31
26
|
const textareaProps = mergeProps(
|
|
32
27
|
{
|
|
33
|
-
isInvalid,
|
|
34
28
|
rows,
|
|
35
29
|
cols,
|
|
36
|
-
variant,
|
|
37
30
|
value,
|
|
38
|
-
isDisabled,
|
|
39
31
|
...expand && { className: s[expand] },
|
|
40
|
-
ref:
|
|
32
|
+
ref: textareaRef
|
|
41
33
|
},
|
|
42
34
|
slotProps?.textarea
|
|
43
35
|
);
|
|
44
|
-
const captionProps = mergeProps(
|
|
36
|
+
const captionProps = mergeProps(
|
|
37
|
+
{ children: caption },
|
|
38
|
+
slotProps?.caption
|
|
39
|
+
);
|
|
45
40
|
const errorProps = mergeProps(
|
|
46
|
-
{ children: errorMessage
|
|
41
|
+
{ children: errorMessage },
|
|
47
42
|
slotProps?.errorMessage
|
|
48
43
|
);
|
|
49
44
|
const groupProps = {
|
|
50
45
|
variant,
|
|
51
46
|
isInvalid,
|
|
47
|
+
className: s.group,
|
|
48
|
+
onMouseDown: (e) => {
|
|
49
|
+
if (e.currentTarget !== e.target) return;
|
|
50
|
+
e.preventDefault();
|
|
51
|
+
textareaRef.current?.focus();
|
|
52
|
+
},
|
|
52
53
|
isDisabled
|
|
53
54
|
};
|
|
54
|
-
const labelProps = mergeProps(
|
|
55
|
+
const labelProps = mergeProps(
|
|
56
|
+
{ isHidden: isLabelHidden, children: label, isRequired },
|
|
57
|
+
slotProps?.label
|
|
58
|
+
);
|
|
55
59
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
56
|
-
/* @__PURE__ */ jsx(
|
|
57
|
-
/* @__PURE__ */ jsxs(
|
|
58
|
-
/* @__PURE__ */ jsx(
|
|
59
|
-
/* @__PURE__ */ jsx(
|
|
60
|
-
/* @__PURE__ */ jsx(
|
|
60
|
+
/* @__PURE__ */ jsx(FormField.Label, { ...labelProps }),
|
|
61
|
+
/* @__PURE__ */ jsxs("div", { className: s.body, children: [
|
|
62
|
+
/* @__PURE__ */ jsx(FormField.ControlGroup, { ...groupProps, children: /* @__PURE__ */ jsx(FormField.Input, { as: "textarea", ...textareaProps }) }),
|
|
63
|
+
/* @__PURE__ */ jsx(FormField.Caption, { ...captionProps }),
|
|
64
|
+
/* @__PURE__ */ jsx(FormField.Error, { ...errorProps })
|
|
61
65
|
] })
|
|
62
66
|
] });
|
|
63
67
|
});
|
|
@@ -1,17 +1,15 @@
|
|
|
1
1
|
import type { ComponentRef, CSSProperties, ReactNode } from 'react';
|
|
2
2
|
import type { ExtendableProps } from '@koobiq/react-core';
|
|
3
3
|
import type { TextFieldProps } from '@koobiq/react-primitives';
|
|
4
|
-
import {
|
|
5
|
-
import { type FormControlPropLabelAlign, type FormControlPropLabelPlacement } from '../FormControl';
|
|
6
|
-
import type { FormControlLabelProps } from '../FormControlLabel';
|
|
4
|
+
import type { FormFieldLabelProps, FormFieldInputProps, FormFieldErrorProps, FormFieldCaptionProps, FormFieldPropLabelAlign, FormFieldPropLabelPlacement, FormFieldControlGroupPropVariant } from '../FormField';
|
|
7
5
|
export declare const textareaPropVariant: readonly ["filled", "transparent"];
|
|
8
|
-
export type TextareaPropVariant =
|
|
6
|
+
export type TextareaPropVariant = FormFieldControlGroupPropVariant;
|
|
9
7
|
export declare const textareaPropExpand: readonly ["auto-size", "vertical-resize"];
|
|
10
8
|
export type TextareaPropExpand = (typeof textareaPropExpand)[number];
|
|
11
9
|
export declare const textareaPropLabelPlacement: readonly ["top", "side"];
|
|
12
|
-
export type TextareaPropLabelPlacement =
|
|
10
|
+
export type TextareaPropLabelPlacement = FormFieldPropLabelPlacement;
|
|
13
11
|
export declare const textareaPropLabelAlign: readonly ["start", "end"];
|
|
14
|
-
export type TextareaPropLabelAlign =
|
|
12
|
+
export type TextareaPropLabelAlign = FormFieldPropLabelAlign;
|
|
15
13
|
type TextareaDeprecatedProps = {
|
|
16
14
|
/**
|
|
17
15
|
* If `true`, the component is disabled.
|
|
@@ -89,10 +87,10 @@ export type TextareaProps = ExtendableProps<{
|
|
|
89
87
|
'data-testid'?: string | number;
|
|
90
88
|
/** The props used for each slot inside. */
|
|
91
89
|
slotProps?: {
|
|
92
|
-
label?:
|
|
93
|
-
caption?:
|
|
94
|
-
textarea?:
|
|
95
|
-
errorMessage?:
|
|
90
|
+
label?: FormFieldLabelProps;
|
|
91
|
+
caption?: FormFieldCaptionProps;
|
|
92
|
+
textarea?: FormFieldInputProps<'textarea'>;
|
|
93
|
+
errorMessage?: FormFieldErrorProps;
|
|
96
94
|
};
|
|
97
95
|
}, TextareaDeprecatedProps & Omit<TextFieldProps<HTMLTextAreaElement>, 'description' | 'validationState' | 'children' | 'style' | 'className' | 'inputElementType'>>;
|
|
98
96
|
export type TextareaRef = ComponentRef<'textarea'>;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
const textareaPropVariant =
|
|
1
|
+
import { formFieldControlGroupPropVariant } from "../FormField/FormFieldControlGroup/types.js";
|
|
2
|
+
import { formFieldPropLabelPlacement, formFieldPropLabelAlign } from "../FormField/types.js";
|
|
3
|
+
const textareaPropVariant = formFieldControlGroupPropVariant;
|
|
4
4
|
const textareaPropExpand = ["auto-size", "vertical-resize"];
|
|
5
|
-
const textareaPropLabelPlacement =
|
|
6
|
-
const textareaPropLabelAlign =
|
|
5
|
+
const textareaPropLabelPlacement = formFieldPropLabelPlacement;
|
|
6
|
+
const textareaPropLabelAlign = formFieldPropLabelAlign;
|
|
7
7
|
export {
|
|
8
8
|
textareaPropExpand,
|
|
9
9
|
textareaPropLabelAlign,
|
|
@@ -4,14 +4,9 @@ import { useLocale, useDOMRef, mergeProps, clsx } from "@koobiq/react-core";
|
|
|
4
4
|
import { IconClock16 } from "@koobiq/react-icons";
|
|
5
5
|
import { useSlottedContext, FormContext, useTimeFieldState, removeDataAttributes, useTimeField, FieldErrorContext } from "@koobiq/react-primitives";
|
|
6
6
|
import s from "./TimePicker.module.css.js";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import { Field } from "../FieldComponents/Field/Field.js";
|
|
10
|
-
import { FieldContentGroup } from "../FieldComponents/FieldContentGroup/FieldContentGroup.js";
|
|
11
|
-
import { FieldInputDate } from "../FieldComponents/FieldInputDate/FieldInputDate.js";
|
|
7
|
+
import { useForm } from "../Form/FormContext.js";
|
|
8
|
+
import { FormField } from "../FormField/FormField.js";
|
|
12
9
|
import { DateSegment } from "../DateSegment/DateSegment.js";
|
|
13
|
-
import { FieldCaption } from "../FieldComponents/FieldCaption/FieldCaption.js";
|
|
14
|
-
import { FieldError } from "../FieldComponents/FieldError/FieldError.js";
|
|
15
10
|
function TimePickerRender(props, ref) {
|
|
16
11
|
const { locale } = useLocale();
|
|
17
12
|
const domRef = useDOMRef(ref);
|
|
@@ -23,6 +18,9 @@ function TimePickerRender(props, ref) {
|
|
|
23
18
|
caption,
|
|
24
19
|
label,
|
|
25
20
|
slotProps,
|
|
21
|
+
isDisabled: isDisabledProp,
|
|
22
|
+
isReadOnly: isReadOnlyProp,
|
|
23
|
+
isRequired,
|
|
26
24
|
style,
|
|
27
25
|
fullWidth,
|
|
28
26
|
variant,
|
|
@@ -31,10 +29,13 @@ function TimePickerRender(props, ref) {
|
|
|
31
29
|
startAddon,
|
|
32
30
|
"data-testid": testId
|
|
33
31
|
} = props;
|
|
32
|
+
const { isDisabled: formIsDisabled, isReadOnly: formIsReadOnly } = useForm();
|
|
33
|
+
const isDisabled = isDisabledProp ?? formIsDisabled;
|
|
34
|
+
const isReadOnly = isReadOnlyProp ?? formIsReadOnly;
|
|
34
35
|
const { validationBehavior: formValidationBehavior } = useSlottedContext(FormContext) || {};
|
|
35
36
|
const validationBehavior = props.validationBehavior ?? formValidationBehavior ?? "aria";
|
|
36
37
|
const state = useTimeFieldState({
|
|
37
|
-
...removeDataAttributes(props),
|
|
38
|
+
...removeDataAttributes({ ...props, isDisabled, isReadOnly }),
|
|
38
39
|
validationBehavior,
|
|
39
40
|
locale
|
|
40
41
|
});
|
|
@@ -45,8 +46,11 @@ function TimePickerRender(props, ref) {
|
|
|
45
46
|
errorMessageProps,
|
|
46
47
|
inputProps,
|
|
47
48
|
...validation
|
|
48
|
-
} = useTimeField(
|
|
49
|
-
|
|
49
|
+
} = useTimeField(
|
|
50
|
+
removeDataAttributes({ ...props, isDisabled, isReadOnly }),
|
|
51
|
+
state,
|
|
52
|
+
domRef
|
|
53
|
+
);
|
|
50
54
|
const { isInvalid } = validation;
|
|
51
55
|
const rootProps = mergeProps(
|
|
52
56
|
{
|
|
@@ -70,6 +74,11 @@ function TimePickerRender(props, ref) {
|
|
|
70
74
|
startAddon,
|
|
71
75
|
/* @__PURE__ */ jsx(IconClock16, { className: s.clock })
|
|
72
76
|
] }),
|
|
77
|
+
onMouseDown: (e) => {
|
|
78
|
+
if (e.currentTarget !== e.target) return;
|
|
79
|
+
e.preventDefault();
|
|
80
|
+
labelPropReactAria?.onClick?.(e);
|
|
81
|
+
},
|
|
73
82
|
variant,
|
|
74
83
|
isInvalid,
|
|
75
84
|
isDisabled,
|
|
@@ -78,44 +87,41 @@ function TimePickerRender(props, ref) {
|
|
|
78
87
|
slotProps?.group
|
|
79
88
|
);
|
|
80
89
|
const controlProps = mergeProps(
|
|
81
|
-
{
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
isDisabled,
|
|
85
|
-
ref: domRef
|
|
86
|
-
},
|
|
87
|
-
slotProps?.inputDate,
|
|
88
|
-
fieldProps
|
|
90
|
+
{ ref: domRef },
|
|
91
|
+
fieldProps,
|
|
92
|
+
slotProps?.inputDate
|
|
89
93
|
);
|
|
90
94
|
const labelProps = mergeProps(
|
|
91
95
|
{ isHidden: isLabelHidden, children: label, isRequired },
|
|
92
96
|
labelPropReactAria,
|
|
93
97
|
slotProps?.label
|
|
94
98
|
);
|
|
95
|
-
const captionProps = mergeProps(
|
|
99
|
+
const captionProps = mergeProps(
|
|
100
|
+
{ children: caption },
|
|
101
|
+
descriptionProps,
|
|
102
|
+
slotProps?.caption
|
|
103
|
+
);
|
|
96
104
|
const errorProps = mergeProps(
|
|
97
|
-
{
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
slotProps?.errorMessage,
|
|
101
|
-
errorMessageProps
|
|
105
|
+
{ children: errorMessage },
|
|
106
|
+
errorMessageProps,
|
|
107
|
+
slotProps?.errorMessage
|
|
102
108
|
);
|
|
103
|
-
return /* @__PURE__ */ jsxs(
|
|
104
|
-
/* @__PURE__ */ jsx(
|
|
105
|
-
/* @__PURE__ */ jsxs(
|
|
109
|
+
return /* @__PURE__ */ jsxs(FormField, { ...rootProps, children: [
|
|
110
|
+
/* @__PURE__ */ jsx(FormField.Label, { ...labelProps }),
|
|
111
|
+
/* @__PURE__ */ jsxs("div", { className: s.body, children: [
|
|
106
112
|
/* @__PURE__ */ jsx(
|
|
107
|
-
|
|
113
|
+
FormField.ControlGroup,
|
|
108
114
|
{
|
|
109
115
|
...groupProps,
|
|
110
116
|
slotProps: { startAddon: { className: s.startAddon } },
|
|
111
|
-
children: /* @__PURE__ */ jsxs(
|
|
117
|
+
children: /* @__PURE__ */ jsxs(FormField.InputDate, { ...controlProps, children: [
|
|
112
118
|
state.segments.map((segment, i) => /* @__PURE__ */ jsx(DateSegment, { segment, state }, i)),
|
|
113
119
|
/* @__PURE__ */ jsx("input", { ...inputProps })
|
|
114
120
|
] })
|
|
115
121
|
}
|
|
116
122
|
),
|
|
117
|
-
/* @__PURE__ */ jsx(
|
|
118
|
-
/* @__PURE__ */ jsx(FieldErrorContext.Provider, { value: validation, children: /* @__PURE__ */ jsx(
|
|
123
|
+
/* @__PURE__ */ jsx(FormField.Caption, { ...captionProps }),
|
|
124
|
+
/* @__PURE__ */ jsx(FieldErrorContext.Provider, { value: validation, children: /* @__PURE__ */ jsx(FormField.Error, { ...errorProps }) })
|
|
119
125
|
] })
|
|
120
126
|
] });
|
|
121
127
|
}
|
|
@@ -1,13 +1,16 @@
|
|
|
1
1
|
const base = "kbq-timepicker-a6e9f3";
|
|
2
2
|
const startAddon = "kbq-timepicker-startAddon-46c835";
|
|
3
3
|
const clock = "kbq-timepicker-clock-920ed0";
|
|
4
|
+
const body = "kbq-timepicker-body-15a987";
|
|
4
5
|
const s = {
|
|
5
6
|
base,
|
|
6
7
|
startAddon,
|
|
7
|
-
clock
|
|
8
|
+
clock,
|
|
9
|
+
body
|
|
8
10
|
};
|
|
9
11
|
export {
|
|
10
12
|
base,
|
|
13
|
+
body,
|
|
11
14
|
clock,
|
|
12
15
|
s as default,
|
|
13
16
|
startAddon
|
|
@@ -1,13 +1,11 @@
|
|
|
1
1
|
import type { ComponentRef, CSSProperties, ReactElement, ReactNode, Ref } from 'react';
|
|
2
2
|
import type { AriaTimeFieldProps, TimeValue } from '@koobiq/react-primitives';
|
|
3
3
|
import type { DateInputPropVariant } from '../DateInput';
|
|
4
|
-
import { type
|
|
5
|
-
import { type FormControlProps, type FormControlPropLabelAlign, type FormControlPropLabelPlacement } from '../FormControl';
|
|
6
|
-
import type { FormControlLabelProps } from '../FormControlLabel';
|
|
4
|
+
import { type FormFieldLabelProps, type FormFieldCaptionProps, type FormFieldErrorProps, type FormFieldInputDateProps, type FormFieldControlGroupProps, type FormFieldProps, type FormFieldPropLabelAlign, type FormFieldPropLabelPlacement } from '../FormField';
|
|
7
5
|
export declare const timePickerPropLabelPlacement: readonly ["top", "side"];
|
|
8
|
-
export type TimePickerPropLabelPlacement =
|
|
6
|
+
export type TimePickerPropLabelPlacement = FormFieldPropLabelPlacement;
|
|
9
7
|
export declare const timePickerPropLabelAlign: readonly ["start", "end"];
|
|
10
|
-
export type TimePickerPropLabelAlign =
|
|
8
|
+
export type TimePickerPropLabelAlign = FormFieldPropLabelAlign;
|
|
11
9
|
export type TimePickerProps<T extends TimeValue> = {
|
|
12
10
|
/** Inline styles. */
|
|
13
11
|
style?: CSSProperties;
|
|
@@ -28,12 +26,12 @@ export type TimePickerProps<T extends TimeValue> = {
|
|
|
28
26
|
fullWidth?: boolean;
|
|
29
27
|
/** The props used for each slot inside. */
|
|
30
28
|
slotProps?: {
|
|
31
|
-
root?:
|
|
32
|
-
label?:
|
|
33
|
-
group?:
|
|
34
|
-
caption?:
|
|
35
|
-
inputDate?:
|
|
36
|
-
errorMessage?:
|
|
29
|
+
root?: FormFieldProps;
|
|
30
|
+
label?: FormFieldLabelProps;
|
|
31
|
+
group?: FormFieldControlGroupProps;
|
|
32
|
+
caption?: FormFieldCaptionProps;
|
|
33
|
+
inputDate?: FormFieldInputDateProps;
|
|
34
|
+
errorMessage?: FormFieldErrorProps;
|
|
37
35
|
};
|
|
38
36
|
/** Ref to the control */
|
|
39
37
|
ref?: Ref<HTMLDivElement>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
const timePickerPropLabelPlacement =
|
|
3
|
-
const timePickerPropLabelAlign =
|
|
1
|
+
import { formFieldPropLabelPlacement, formFieldPropLabelAlign } from "../FormField/types.js";
|
|
2
|
+
const timePickerPropLabelPlacement = formFieldPropLabelPlacement;
|
|
3
|
+
const timePickerPropLabelAlign = formFieldPropLabelAlign;
|
|
4
4
|
export {
|
|
5
5
|
timePickerPropLabelAlign,
|
|
6
6
|
timePickerPropLabelPlacement
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type SwitchProps } from '@koobiq/react-primitives';
|
|
2
|
-
export declare const Toggle: import("react").ForwardRefExoticComponent<Omit<Omit<SwitchProps, "inputRef">, "children" | "style" | "className" | "size" | "
|
|
2
|
+
export declare const Toggle: import("react").ForwardRefExoticComponent<Omit<Omit<SwitchProps, "inputRef">, "children" | "style" | "className" | "size" | "slotProps" | "labelPlacement" | keyof {
|
|
3
3
|
disabled?: boolean;
|
|
4
4
|
error?: boolean;
|
|
5
5
|
checked?: boolean;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const Tooltip: import("react").ForwardRefExoticComponent<Omit<import("@react-types/tooltip").TooltipTriggerProps, "children" | "className" | "id" | "offset" | "
|
|
1
|
+
export declare const Tooltip: import("react").ForwardRefExoticComponent<Omit<import("@react-types/tooltip").TooltipTriggerProps, "children" | "className" | "id" | "offset" | "placement" | `data-${string}` | "variant" | "control" | "portalContainer" | "anchorRef" | "hideArrow" | "arrowBoundaryOffset" | "crossOffset" | "delay" | "closeDelay" | keyof {
|
|
2
2
|
open?: boolean;
|
|
3
3
|
disabled?: boolean;
|
|
4
4
|
}> & {
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
export * from './Provider';
|
|
2
2
|
export * from './FlexBox';
|
|
3
3
|
export * from './Container';
|
|
4
|
-
export * from './
|
|
5
|
-
export * from './FormControlLabel';
|
|
4
|
+
export * from './FormField';
|
|
6
5
|
export * from './Alert';
|
|
7
6
|
export * from './Button';
|
|
8
7
|
export * from './IconButton';
|
|
@@ -39,5 +38,5 @@ export * from './TimePicker';
|
|
|
39
38
|
export * from './SearchInput';
|
|
40
39
|
export * from './Form';
|
|
41
40
|
export * from './layout';
|
|
42
|
-
export { useListData, type ListData, type ListOptions, type TimeValue, type DateValue, } from '@koobiq/react-primitives';
|
|
43
|
-
export { useRouter, useLocale, type Locale, RouterProvider, useDateFormatter, } from '@koobiq/react-core';
|
|
41
|
+
export { useListData, useAsyncList, type ListData, type ListOptions, type AsyncListData, type AsyncListOptions, type AsyncListLoadFunction, type AsyncListLoadOptions, type TimeValue, type DateValue, } from '@koobiq/react-primitives';
|
|
42
|
+
export { useRouter, useLocale, type Locale, type SortDescriptor, type Selection, RouterProvider, useDateFormatter, } from '@koobiq/react-core';
|