@alma-oss/spirit-web-react 4.1.0 → 4.2.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/bundles/web-react.umd.js +318 -145
- package/bundles/web-react.umd.js.map +1 -1
- package/bundles/web-react.umd.min.js +1 -1
- package/bundles/web-react.umd.min.js.map +1 -1
- package/components/Accordion/Accordion.cjs +22 -6
- package/components/Accordion/Accordion.cjs.map +1 -1
- package/components/Accordion/Accordion.d.ts +5 -3
- package/components/Accordion/Accordion.js +2 -0
- package/components/Accordion/Accordion.js.map +1 -1
- package/components/Accordion/AccordionHeader.d.ts +5 -3
- package/components/Accordion/AccordionHeader.js +14 -4
- package/components/Accordion/AccordionHeader.js.map +1 -1
- package/components/Accordion/AccordionItem.d.ts +5 -3
- package/components/Accordion/AccordionItem.js +2 -0
- package/components/Accordion/AccordionItem.js.map +1 -1
- package/components/Accordion/UncontrolledAccordion.d.ts +5 -3
- package/components/Accordion/UncontrolledAccordion.js +3 -1
- package/components/Accordion/UncontrolledAccordion.js.map +1 -1
- package/components/Accordion/useAccordion.d.ts +2 -2
- package/components/Accordion/useAccordion.js.map +1 -1
- package/components/ActionGroup/ActionGroup.cjs +2 -0
- package/components/ActionGroup/ActionGroup.cjs.map +1 -1
- package/components/Card/CardLink.d.ts +1 -1
- package/components/FileUploader/FileUploader.cjs +6 -4
- package/components/FileUploader/FileUploader.cjs.map +1 -1
- package/components/FileUploader/FileUploaderAttachment.js +3 -3
- package/components/FileUploader/FileUploaderAttachment.js.map +1 -1
- package/components/FileUploader/FileUploaderList.js +2 -1
- package/components/FileUploader/FileUploaderList.js.map +1 -1
- package/components/FileUploader/constants.d.ts +1 -0
- package/components/FileUploader/constants.js +1 -0
- package/components/FileUploader/constants.js.map +1 -1
- package/components/Flex/Flex.cjs +2 -0
- package/components/Flex/Flex.cjs.map +1 -1
- package/components/Flex/Flex.d.ts +2 -0
- package/components/Flex/Flex.js +2 -0
- package/components/Flex/Flex.js.map +1 -1
- package/components/Flex/useFlexStyleProps.d.ts +2 -2
- package/components/Footer/Footer.cjs +40 -3
- package/components/Footer/Footer.cjs.map +1 -1
- package/components/Footer/Footer.d.ts +2 -2
- package/components/Footer/Footer.js +5 -3
- package/components/Footer/Footer.js.map +1 -1
- package/components/Footer/useFooterStyleProps.d.ts +2 -2
- package/components/Footer/useFooterStyleProps.js.map +1 -1
- package/components/Grid/Grid.cjs +4 -0
- package/components/Grid/Grid.cjs.map +1 -1
- package/components/Grid/Grid.d.ts +2 -0
- package/components/Grid/Grid.js +2 -0
- package/components/Grid/Grid.js.map +1 -1
- package/components/Grid/GridItem.d.ts +2 -0
- package/components/Grid/GridItem.js +2 -0
- package/components/Grid/GridItem.js.map +1 -1
- package/components/Grid/useGridItemStyleProps.d.ts +2 -2
- package/components/Grid/useGridStyleProps.d.ts +2 -2
- package/components/Icon/useIconStyleProps.d.ts +10 -10
- package/components/Modal/Modal.cjs +4 -2
- package/components/Modal/Modal.cjs.map +1 -1
- package/components/Modal/ModalCloseButton.js +2 -1
- package/components/Modal/ModalCloseButton.js.map +1 -1
- package/components/Modal/ModalHeader.js +2 -1
- package/components/Modal/ModalHeader.js.map +1 -1
- package/components/Modal/constants.d.ts +1 -0
- package/components/Modal/constants.js +2 -0
- package/components/Modal/constants.js.map +1 -0
- package/components/Pagination/Pagination.cjs +11 -6
- package/components/Pagination/Pagination.cjs.map +1 -1
- package/components/Pagination/PaginationButtonLink.js +4 -1
- package/components/Pagination/PaginationButtonLink.js.map +1 -1
- package/components/Pagination/PaginationLink.js +3 -1
- package/components/Pagination/PaginationLink.js.map +1 -1
- package/components/Pagination/UncontrolledPagination.js +2 -1
- package/components/Pagination/UncontrolledPagination.js.map +1 -1
- package/components/Pagination/constants.d.ts +1 -0
- package/components/Pagination/constants.js +1 -0
- package/components/Pagination/constants.js.map +1 -1
- package/components/PricingPlan/PricingPlan.cjs +4 -2
- package/components/PricingPlan/PricingPlan.cjs.map +1 -1
- package/components/ScrollView/ScrollView.cjs +41 -8
- package/components/ScrollView/ScrollView.cjs.map +1 -1
- package/components/ScrollView/ScrollViewArrows.js +3 -8
- package/components/ScrollView/ScrollViewArrows.js.map +1 -1
- package/components/ScrollView/constants.d.ts +1 -0
- package/components/ScrollView/constants.js +1 -0
- package/components/ScrollView/constants.js.map +1 -1
- package/components/ScrollView/index.d.ts +1 -0
- package/components/ScrollView/index.js +1 -0
- package/components/ScrollView/index.js.map +1 -1
- package/components/ScrollView/useScrollCallback.d.ts +10 -0
- package/components/ScrollView/useScrollCallback.js +41 -0
- package/components/ScrollView/useScrollCallback.js.map +1 -0
- package/components/Skeleton/useSkeletonShapeStyleProps.d.ts +10 -10
- package/components/SplitButton/SplitButton.cjs +3 -0
- package/components/SplitButton/SplitButton.cjs.map +1 -1
- package/components/SplitButton/UncontrolledSplitButton.js +2 -0
- package/components/SplitButton/UncontrolledSplitButton.js.map +1 -1
- package/components/SplitButton/constants.d.ts +1 -0
- package/components/SplitButton/constants.js +2 -0
- package/components/SplitButton/constants.js.map +1 -0
- package/components/TextArea/TextArea.cjs +7 -1
- package/components/TextArea/TextArea.cjs.map +1 -1
- package/components/TextField/TextField.cjs +7 -1
- package/components/TextField/TextField.cjs.map +1 -1
- package/components/TextFieldBase/TextFieldBase.cjs +7 -1
- package/components/TextFieldBase/TextFieldBase.cjs.map +1 -1
- package/components/TextFieldBase/TextFieldBase.d.ts +2 -2
- package/components/TextFieldBase/TextFieldBasePasswordToggle.js +5 -1
- package/components/TextFieldBase/TextFieldBasePasswordToggle.js.map +1 -1
- package/components/TextFieldBase/constants.d.ts +2 -0
- package/components/TextFieldBase/constants.js +3 -0
- package/components/TextFieldBase/constants.js.map +1 -0
- package/components/Toast/Toast.cjs +1 -1
- package/components/Toast/Toast.cjs.map +1 -1
- package/components/Toast/UncontrolledToast.js +2 -1
- package/components/Toast/UncontrolledToast.js.map +1 -1
- package/components/Toast/useToastBarStyleProps.d.ts +10 -10
- package/components/components.cjs +105 -30
- package/components/components.cjs.map +1 -1
- package/index.cjs +105 -30
- package/index.cjs.map +1 -1
- package/package.json +8 -6
- package/spirit-web-react.cjs +105 -30
- package/spirit-web-react.cjs.map +1 -1
- package/spirit-web-react.min.cjs +1 -1
- package/types/accordion.d.ts +14 -7
- package/types/box.d.ts +2 -2
- package/types/flex.d.ts +2 -3
- package/types/footer.d.ts +7 -2
- package/types/grid.d.ts +3 -5
package/types/accordion.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ElementType, type ReactNode } from 'react';
|
|
2
|
-
import { type ChildrenProps, type ElementTypeProps, type
|
|
2
|
+
import { type ChildrenProps, type ElementTypeProps, type SpiritPolymorphicElementPropsWithRef, type StyleProps } from './shared';
|
|
3
3
|
export type AccordionOpenStateType = string | string[] | undefined;
|
|
4
4
|
export interface AccordionHandlingProps {
|
|
5
5
|
open: AccordionOpenStateType;
|
|
@@ -8,18 +8,25 @@ export interface AccordionHandlingProps {
|
|
|
8
8
|
export interface AccordionItemContextProps {
|
|
9
9
|
id: string;
|
|
10
10
|
}
|
|
11
|
-
export interface BaseAccordionProps extends ChildrenProps, StyleProps
|
|
11
|
+
export interface BaseAccordionProps extends ChildrenProps, StyleProps {
|
|
12
12
|
}
|
|
13
|
-
export interface
|
|
13
|
+
export interface AccordionBaseProps extends BaseAccordionProps, AccordionHandlingProps {
|
|
14
14
|
}
|
|
15
|
-
export
|
|
15
|
+
export type AccordionProps<T extends ElementType> = ElementTypeProps<T> & AccordionBaseProps;
|
|
16
|
+
export type SpiritAccordionProps<T extends ElementType = 'section'> = AccordionProps<T> & SpiritPolymorphicElementPropsWithRef<T, AccordionProps<T>>;
|
|
17
|
+
export type AccordionHeaderProps<T extends ElementType = 'h3'> = ElementTypeProps<T> & {
|
|
16
18
|
slot?: ReactNode;
|
|
19
|
+
} & BaseAccordionProps;
|
|
20
|
+
export type SpiritAccordionHeaderProps<T extends ElementType = 'h3'> = AccordionHeaderProps<T> & SpiritPolymorphicElementPropsWithRef<T, AccordionHeaderProps<T>>;
|
|
21
|
+
export interface AccordionItemBaseProps extends BaseAccordionProps, AccordionItemContextProps {
|
|
17
22
|
}
|
|
18
|
-
export
|
|
19
|
-
|
|
23
|
+
export type AccordionItemProps<T extends ElementType> = ElementTypeProps<T> & AccordionItemBaseProps;
|
|
24
|
+
export type SpiritAccordionItemProps<T extends ElementType = 'article'> = AccordionItemProps<T> & SpiritPolymorphicElementPropsWithRef<T, AccordionItemProps<T>>;
|
|
20
25
|
export interface AccordionContentProps extends BaseAccordionProps {
|
|
21
26
|
}
|
|
22
|
-
export interface
|
|
27
|
+
export interface UncontrolledAccordionBaseProps extends BaseAccordionProps {
|
|
23
28
|
defaultOpen?: AccordionOpenStateType;
|
|
24
29
|
stayOpen?: boolean;
|
|
25
30
|
}
|
|
31
|
+
export type UncontrolledAccordionProps<T extends ElementType> = ElementTypeProps<T> & UncontrolledAccordionBaseProps;
|
|
32
|
+
export type SpiritUncontrolledAccordionProps<T extends ElementType = 'section'> = UncontrolledAccordionProps<T> & SpiritPolymorphicElementPropsWithRef<T, UncontrolledAccordionProps<T>>;
|
package/types/box.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ElementType, type JSXElementConstructor } from 'react';
|
|
2
|
-
import { type BackgroundAccentColorsType, type BackgroundColorsDictionaryType, type BackgroundEmotionColorsType, type BackgroundGradientsDictionaryType, type BackgroundNeutralColorsType, type BorderAccentColorsType, type BorderColorsDictionaryType, type BorderEmotionColorsType, type BorderRadiiTokenType, type BorderStylesDictionaryType, type BorderWidthsDictionaryType, type ChildrenProps, type SingleOrResponsive, type SpaceToken, type
|
|
2
|
+
import { type BackgroundAccentColorsType, type BackgroundColorsDictionaryType, type BackgroundEmotionColorsType, type BackgroundGradientsDictionaryType, type BackgroundNeutralColorsType, type BorderAccentColorsType, type BorderColorsDictionaryType, type BorderEmotionColorsType, type BorderRadiiTokenType, type BorderStylesDictionaryType, type BorderWidthsDictionaryType, type ChildrenProps, type SingleOrResponsive, type SpaceToken, type SpiritPolymorphicElementPropsWithRef, type StyleProps, type TextColorProps } from './shared';
|
|
3
3
|
export type BoxBackgroundColorsType = BackgroundColorsDictionaryType | BackgroundAccentColorsType | BackgroundEmotionColorsType | BackgroundNeutralColorsType;
|
|
4
4
|
export interface BoxBaseProps extends ChildrenProps, TextColorProps, StyleProps {
|
|
5
5
|
backgroundColor?: BoxBackgroundColorsType;
|
|
@@ -19,4 +19,4 @@ export interface BoxBaseProps extends ChildrenProps, TextColorProps, StyleProps
|
|
|
19
19
|
export type BoxProps<E extends ElementType> = {
|
|
20
20
|
elementType?: E | JSXElementConstructor<unknown>;
|
|
21
21
|
} & BoxBaseProps;
|
|
22
|
-
export type SpiritBoxProps<E extends ElementType = 'div'> = BoxProps<E> &
|
|
22
|
+
export type SpiritBoxProps<E extends ElementType = 'div'> = BoxProps<E> & SpiritPolymorphicElementPropsWithRef<E, BoxProps<E>>;
|
package/types/flex.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ElementType, type JSXElementConstructor } from 'react';
|
|
2
|
-
import { type AlignmentXExtendedDictionaryType, type AlignmentYExtendedDictionaryType, type ChildrenProps, type DirectionExtendedDictionaryType, type SingleOrResponsive, type SpaceToken, type
|
|
2
|
+
import { type AlignmentXExtendedDictionaryType, type AlignmentYExtendedDictionaryType, type ChildrenProps, type DirectionExtendedDictionaryType, type SingleOrResponsive, type SpaceToken, type SpiritPolymorphicElementPropsWithRef, type StyleProps } from './shared';
|
|
3
3
|
export interface FlexElementTypeProps<T extends ElementType = 'div'> {
|
|
4
4
|
elementType?: T | JSXElementConstructor<unknown>;
|
|
5
5
|
}
|
|
@@ -27,5 +27,4 @@ export interface FlexCustomLayoutProps {
|
|
|
27
27
|
}
|
|
28
28
|
export interface FlexProps<T extends ElementType = 'div'> extends FlexElementTypeProps<T>, FlexCustomLayoutProps {
|
|
29
29
|
}
|
|
30
|
-
export
|
|
31
|
-
}
|
|
30
|
+
export type SpiritFlexProps<T extends ElementType = 'div'> = FlexProps<T> & ChildrenProps & StyleProps & SpiritPolymorphicElementPropsWithRef<T, FlexProps<T>>;
|
package/types/footer.d.ts
CHANGED
|
@@ -1,9 +1,14 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type ElementType } from 'react';
|
|
2
|
+
import { type BackgroundColorsDictionaryType, type ChildrenProps, type SpaceToken, type SpiritPolymorphicElementPropsWithRef, type StyleProps, type TextAlignmentType } from './shared';
|
|
2
3
|
export interface FooterStyleProps {
|
|
3
4
|
paddingTop?: SpaceToken;
|
|
4
5
|
paddingBottom?: SpaceToken;
|
|
5
6
|
backgroundColor?: BackgroundColorsDictionaryType;
|
|
6
7
|
textAlignment?: TextAlignmentType;
|
|
7
8
|
}
|
|
8
|
-
export interface
|
|
9
|
+
export interface FooterBaseProps extends FooterStyleProps, ChildrenProps, StyleProps {
|
|
9
10
|
}
|
|
11
|
+
export type FooterProps<E extends ElementType> = {
|
|
12
|
+
elementType?: E;
|
|
13
|
+
} & FooterBaseProps;
|
|
14
|
+
export type SpiritFooterProps<E extends ElementType = 'footer'> = FooterProps<E> & SpiritPolymorphicElementPropsWithRef<E, FooterProps<E>>;
|
package/types/grid.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ElementType, type JSXElementConstructor } from 'react';
|
|
2
|
-
import { type AlignmentXExtendedDictionaryType, type AlignmentYExtendedDictionaryType, type ChildrenProps, type GridColumns, type SingleOrResponsive, type SpaceToken, type
|
|
2
|
+
import { type AlignmentXExtendedDictionaryType, type AlignmentYExtendedDictionaryType, type ChildrenProps, type GridColumns, type SingleOrResponsive, type SpaceToken, type SpiritPolymorphicElementPropsWithRef, type StyleProps } from './shared';
|
|
3
3
|
export type GridColsBreakpoints = {
|
|
4
4
|
mobile?: GridColumns;
|
|
5
5
|
tablet?: GridColumns;
|
|
@@ -42,7 +42,5 @@ export interface GridProps<T extends ElementType = 'div'> extends GridElementTyp
|
|
|
42
42
|
}
|
|
43
43
|
export interface GridItemProps<T extends ElementType = 'div'> extends GridItemElementTypeProps<T>, GridItemCustomLayoutProps {
|
|
44
44
|
}
|
|
45
|
-
export
|
|
46
|
-
|
|
47
|
-
export interface SpiritGridItemProps<T extends ElementType = 'div'> extends GridItemProps<T>, ChildrenProps, StyleProps, TransferProps {
|
|
48
|
-
}
|
|
45
|
+
export type SpiritGridProps<T extends ElementType = 'div'> = GridProps<T> & ChildrenProps & StyleProps & SpiritPolymorphicElementPropsWithRef<T, GridProps<T>>;
|
|
46
|
+
export type SpiritGridItemProps<T extends ElementType = 'div'> = GridItemProps<T> & ChildrenProps & StyleProps & SpiritPolymorphicElementPropsWithRef<T, GridItemProps<T>>;
|