@obosbbl/grunnmuren-react 3.1.0 → 3.1.1
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/index.d.mts +3 -5
- package/dist/index.mjs +4 -5
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { DisclosureProps as DisclosureProps$1, ButtonProps as ButtonProps$1,
|
|
1
|
+
import { DisclosureProps as DisclosureProps$1, ButtonProps as ButtonProps$1, LinkProps, BreadcrumbProps as BreadcrumbProps$1, BreadcrumbsProps as BreadcrumbsProps$1, ContextValue, CheckboxProps as CheckboxProps$1, CheckboxGroupProps as CheckboxGroupProps$1, HeadingProps as HeadingProps$1, ListBoxItemProps, ListBoxSectionProps, ComboBoxProps, FileTriggerProps as FileTriggerProps$1, RouterProvider, TextProps, LabelProps, DialogProps as DialogProps$1, DialogTriggerProps as DialogTriggerProps$1, ModalOverlayProps, NumberFieldProps as NumberFieldProps$1, RadioProps as RadioProps$1, RadioGroupProps as RadioGroupProps$1, SelectProps as SelectProps$1, TableProps as TableProps$1, TableBodyProps as TableBodyProps$1, CellProps, ColumnProps, TableHeaderProps as TableHeaderProps$1, RowProps, TabProps as TabProps$1, TabListProps as TabListProps$1, TabPanelProps as TabPanelProps$1, TabsProps as TabsProps$1, TagGroupProps as TagGroupProps$1, TagListProps as TagListProps$1, TagProps as TagProps$1, TextFieldProps as TextFieldProps$1 } from 'react-aria-components';
|
|
2
2
|
export { ListBoxItemProps as ComboboxItemProps, Form, Group, LabelProps, ListBoxItemProps as SelectItemProps, DisclosureGroup as UNSAFE_DisclosureGroup, DisclosureGroupProps as UNSAFE_DisclosureGroupProps } from 'react-aria-components';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
4
|
import * as react from 'react';
|
|
5
|
-
import { RefAttributes, HTMLAttributes, ComponentProps, Ref,
|
|
5
|
+
import { RefAttributes, HTMLAttributes, HTMLProps, ComponentProps, Ref, JSX, ReactNode, RefObject, Dispatch, SetStateAction } from 'react';
|
|
6
6
|
import * as cva from 'cva';
|
|
7
7
|
import { VariantProps } from 'cva';
|
|
8
8
|
import { DisclosureState } from 'react-stately';
|
|
@@ -34,10 +34,8 @@ type DisclosurePanelProps = Omit<HTMLAttributes<HTMLDivElement>, 'role'> & {
|
|
|
34
34
|
} & RefAttributes<HTMLDivElement>;
|
|
35
35
|
declare const DisclosurePanel: ({ ref, children, ...props }: DisclosurePanelProps) => react_jsx_runtime.JSX.Element;
|
|
36
36
|
|
|
37
|
-
type AccordionProps =
|
|
37
|
+
type AccordionProps = HTMLProps<HTMLDivElement> & {
|
|
38
38
|
children: React.ReactNode;
|
|
39
|
-
/** Whether multiple accordion items can be expanded at the same time. Default is true */
|
|
40
|
-
allowsMultipleExpanded?: boolean;
|
|
41
39
|
};
|
|
42
40
|
type AccordionItemProps = DisclosureProps & {
|
|
43
41
|
children?: React.ReactNode;
|
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import { useContextProps, DisclosureContext, DisclosureGroupStateContext, Provider, ButtonContext as ButtonContext$1, DEFAULT_SLOT, Button as Button$1,
|
|
2
|
+
import { useContextProps, DisclosureContext, DisclosureGroupStateContext, Provider, ButtonContext as ButtonContext$1, DEFAULT_SLOT, Button as Button$1, useLocale, Link, Breadcrumb as Breadcrumb$1, Breadcrumbs as Breadcrumbs$1, Text, CheckboxContext, Checkbox as Checkbox$1, FieldError, Label as Label$1, CheckboxGroup as CheckboxGroup$1, Header, ListBoxItem as ListBoxItem$1, ListBoxSection as ListBoxSection$1, ListBox as ListBox$1, ComboBox, Group, Input, Popover, useSlottedContext, FormContext, FieldErrorContext, LabelContext, InputContext, I18nProvider, RouterProvider, GroupContext, Dialog as Dialog$1, DialogTrigger as DialogTrigger$1, Modal as Modal$1, ModalOverlay as ModalOverlay$1, NumberField as NumberField$1, Radio as Radio$1, RadioGroup as RadioGroup$1, Select as Select$1, SelectValue, Table as Table$1, TableBody as TableBody$1, Cell, Column, TableHeader as TableHeader$1, Row, Tab as Tab$1, TabListStateContext, TabList as TabList$1, TabPanel as TabPanel$1, Tabs as Tabs$1, TagGroup as TagGroup$1, TagList as TagList$1, Tag as Tag$1, TextField as TextField$1, TextArea as TextArea$1 } from 'react-aria-components';
|
|
3
3
|
export { Form, Group, DisclosureGroup as UNSAFE_DisclosureGroup } from 'react-aria-components';
|
|
4
4
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
5
5
|
import { cva, cx, compose } from 'cva';
|
|
@@ -255,12 +255,11 @@ const DisclosurePanel = ({ ref, children, ...props })=>{
|
|
|
255
255
|
};
|
|
256
256
|
|
|
257
257
|
function Accordion(props) {
|
|
258
|
-
const { children, className,
|
|
258
|
+
const { children, className, ...restProps } = props;
|
|
259
259
|
const childCount = Children.count(children);
|
|
260
|
-
return /*#__PURE__*/ jsx(
|
|
260
|
+
return /*#__PURE__*/ jsx("div", {
|
|
261
261
|
...restProps,
|
|
262
262
|
"data-accordion": true,
|
|
263
|
-
allowsMultipleExpanded: allowsMultipleExpanded,
|
|
264
263
|
className: cx('rounded-lg bg-white', className),
|
|
265
264
|
children: Children.map(children, (child, index)=>/*#__PURE__*/ jsxs(Fragment, {
|
|
266
265
|
children: [
|
|
@@ -275,7 +274,7 @@ function Accordion(props) {
|
|
|
275
274
|
});
|
|
276
275
|
}
|
|
277
276
|
function AccordionItem(props) {
|
|
278
|
-
const { className, children, defaultOpen
|
|
277
|
+
const { className, children, defaultOpen, isOpen: controlledIsOpen, onOpenChange, defaultExpanded = false, isExpanded, onExpandedChange, ...restProps } = props;
|
|
279
278
|
const _defaultExpanded = defaultOpen ?? defaultExpanded;
|
|
280
279
|
const _isExpanded = controlledIsOpen ?? isExpanded;
|
|
281
280
|
const _onExpandedChange = onOpenChange ?? onExpandedChange;
|