@zealicsolutions/web-ui 0.2.58 → 0.2.60

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,11 +1,13 @@
1
- /// <reference types="react" />
1
+ import { PropsWithChildren } from 'react';
2
+ import { CSSProperties } from 'styled-components';
2
3
  import type { Callback } from 'typescript';
3
- export declare type BaseButtonProps = {
4
+ export declare type BaseButtonProps = PropsWithChildren<{
4
5
  onClick?: Callback;
5
6
  variant?: 'primary' | 'secondary';
6
7
  disabled?: boolean;
7
8
  fullWidth?: boolean;
8
- };
9
+ size?: 'medium' | 'small';
10
+ }>;
9
11
  export declare type ButtonProps = BaseButtonProps & {
10
12
  fullWidth?: boolean;
11
13
  text?: string;
@@ -13,5 +15,6 @@ export declare type ButtonProps = BaseButtonProps & {
13
15
  elementId?: string;
14
16
  loading?: boolean;
15
17
  isRichText?: boolean;
18
+ containerStyle?: CSSProperties;
16
19
  };
17
- export declare const Button: ({ text, onClick, loading, disabled, variant, isRichText, fullWidth, elementId, link, }: ButtonProps) => JSX.Element | null;
20
+ export declare const Button: ({ text: textProp, onClick, loading, disabled, variant, isRichText, fullWidth, elementId, link, containerStyle, children, size, }: ButtonProps) => JSX.Element | null;
@@ -1,15 +1,15 @@
1
1
  import type { ComponentStory } from '@storybook/react';
2
2
  import { FC } from 'react';
3
+ import { TextButtonProps } from 'atoms/Buttons/TextButton';
3
4
  import { Button as ButtonComponent } from './Button';
4
- import { LinkButtonProps } from './LinkButton';
5
5
  import { TouchableOpacityProps } from './TouchableOpacity';
6
6
  import { IconButton as IconButtonComponent } from './IconButton';
7
7
  declare const _default: {
8
8
  title: string;
9
- component: ({ text, onClick, loading, disabled, variant, isRichText, fullWidth, elementId, link, }: import("./Button").ButtonProps) => JSX.Element | null;
9
+ component: ({ text: textProp, onClick, loading, disabled, variant, isRichText, fullWidth, elementId, link, containerStyle, children, size, }: import("./Button").ButtonProps) => JSX.Element | null;
10
10
  };
11
11
  export default _default;
12
12
  export declare const Button: ComponentStory<typeof ButtonComponent>;
13
13
  export declare const TouchableOpacity: ComponentStory<FC<TouchableOpacityProps>>;
14
- export declare const LinkButton: ComponentStory<FC<LinkButtonProps>>;
14
+ export declare const TextButton: ComponentStory<FC<TextButtonProps>>;
15
15
  export declare const IconButton: ComponentStory<typeof IconButtonComponent>;
@@ -1,6 +1,6 @@
1
1
  import { PropsWithChildren } from 'react';
2
2
  import type { Callback } from 'typescript';
3
- export declare type LinkButtonProps = PropsWithChildren<{
3
+ export declare type TextButtonProps = PropsWithChildren<{
4
4
  activeOpacity?: number;
5
5
  withoutOpacityEffect?: boolean;
6
6
  disabled?: boolean;
@@ -8,7 +8,7 @@ export declare type LinkButtonProps = PropsWithChildren<{
8
8
  buttonLink?: string;
9
9
  elementId?: string;
10
10
  }>;
11
- export declare const LinkButton: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
11
+ export declare const TextButton: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
12
12
  activeOpacity?: number | undefined;
13
13
  withoutOpacityEffect?: boolean | undefined;
14
14
  disabled?: boolean | undefined;
@@ -8,7 +8,7 @@ export * from './Icon/Icon';
8
8
  export * from './Spacer/Spacer';
9
9
  export * from './Spinner/Spinner';
10
10
  export * from './Image/Image';
11
- export * from './Buttons/LinkButton';
11
+ export * from './Buttons/TextButton';
12
12
  export * from './ValidationTag/ValidationTag';
13
13
  export * from './Video/Video';
14
14
  export * from './Tooltip/Tooltip';
@@ -2,4 +2,4 @@ import { CSSProperties } from 'styled-components';
2
2
  export declare const getSizeStyle: (size: number) => Pick<CSSProperties, 'maxWidth' | 'maxHeight' | 'minWidth' | 'minHeight'>;
3
3
  export declare const changeColorTint: (color: string, percent: number) => string;
4
4
  export declare const getTintColor: (color: string) => string;
5
- export declare const getShadeColor: (color: string) => string;
5
+ export declare const getShadeColor: (color: string, percent?: number) => string;
@@ -1,5 +1,5 @@
1
1
  import { CSSProperties } from 'react';
2
- import { LinkButtonProps } from 'atoms';
2
+ import { TextButtonProps } from 'atoms';
3
3
  import { ColumnsTemplateKeys } from './types';
4
4
  export declare type ColumnsProps = {
5
5
  type: 'columns';
@@ -10,7 +10,7 @@ export declare type ColumnsProps = {
10
10
  export declare type ColumnItem = {
11
11
  title?: string;
12
12
  mainContent?: string;
13
- button?: LinkButtonProps;
13
+ button?: TextButtonProps;
14
14
  icon: string;
15
15
  };
16
16
  export declare const Columns: ({ columns, containerStyles, template }: ColumnsProps) => JSX.Element;
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
- import { LinkButtonProps } from 'atoms';
3
- export declare const useAnnotationCircle: (linkButton?: LinkButtonProps) => {
2
+ import { TextButtonProps } from 'atoms';
3
+ export declare const useAnnotationCircle: (linkButton?: TextButtonProps) => {
4
4
  circleJSX: false | JSX.Element;
5
5
  };
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import { ConsentProps } from 'organisms/Consent/Consent';
3
3
  import type { Callback } from 'typescript';
4
- import { UIFields } from '../../fieldsConfiguration';
4
+ import { UIFields } from 'fieldsConfiguration';
5
5
  import { TwoFactorAuthProps } from '../TwoFactorAuth/TwoFactorAuth';
6
6
  import { LoginFields } from './types';
7
7
  export declare type LoginFormProps = {
package/dist/index.d.ts CHANGED
@@ -1,9 +1,9 @@
1
1
  /// <reference types="react" />
2
- import { Callback as Callback$1, StylesType, Nullable } from 'typescript';
3
2
  import * as React$1 from 'react';
4
3
  import React__default, { PropsWithChildren, ReactNode, CSSProperties as CSSProperties$1, ComponentType, Dispatch, SetStateAction } from 'react';
5
4
  import * as styled_components from 'styled-components';
6
5
  import { CSSProperties, DefaultTheme } from 'styled-components';
6
+ import { Callback as Callback$1, StylesType, Nullable } from 'typescript';
7
7
  import { IconNames as IconNames$1 } from 'atoms/Icon/Icon';
8
8
  import { InputFieldTypes as InputFieldTypes$1, FieldTypes as FieldTypes$1, UIFields as UIFields$1 } from 'fieldsConfiguration/types';
9
9
  import * as _mui_material_OverridableComponent from '@mui/material/OverridableComponent';
@@ -15,7 +15,7 @@ import { FeedContentTemplateTypes as FeedContentTemplateTypes$1, FeedContentProp
15
15
  import { TooltipProps as TooltipProps$1 } from 'rc-tooltip/lib/Tooltip';
16
16
  import { WithGoogleMapProps } from 'react-google-maps/lib/withGoogleMap';
17
17
  import { WithScriptjsProps } from 'react-google-maps/lib/withScriptjs';
18
- import { IconNames as IconNames$2, TouchableOpacityProps as TouchableOpacityProps$1, InputProps as InputProps$1, ImageProps as ImageProps$1, ButtonProps as ButtonProps$1, LinkButtonProps as LinkButtonProps$1, RadioButtonsProps as RadioButtonsProps$1, HorizontalButtonsProps as HorizontalButtonsProps$1, IconProps as IconProps$1 } from 'atoms';
18
+ import { IconNames as IconNames$2, TouchableOpacityProps as TouchableOpacityProps$1, InputProps as InputProps$1, ImageProps as ImageProps$1, ButtonProps as ButtonProps$1, TextButtonProps as TextButtonProps$1, RadioButtonsProps as RadioButtonsProps$1, HorizontalButtonsProps as HorizontalButtonsProps$1, IconProps as IconProps$1 } from 'atoms';
19
19
  import { Control, ControllerProps } from 'react-hook-form/dist/types';
20
20
  import { SelectOption as SelectOption$1 } from 'atoms/Select/types';
21
21
  import { ControllerProps as ControllerProps$1, DeepPartial, FieldValues, FormState, Control as Control$1 } from 'react-hook-form';
@@ -37,12 +37,13 @@ import { LoginFields as LoginFields$1 } from 'organisms/LoginForm/types';
37
37
  import { AnnotationsList as AnnotationsList$1 } from 'contexts/MlrRichTextViewerContext/types';
38
38
  import * as contexts_MlrRichTextViewerContext_MlrRichTextViewerContext from 'contexts/MlrRichTextViewerContext/MlrRichTextViewerContext';
39
39
 
40
- declare type BaseButtonProps = {
40
+ declare type BaseButtonProps = PropsWithChildren<{
41
41
  onClick?: Callback$1;
42
42
  variant?: 'primary' | 'secondary';
43
43
  disabled?: boolean;
44
44
  fullWidth?: boolean;
45
- };
45
+ size?: 'medium' | 'small';
46
+ }>;
46
47
  declare type ButtonProps = BaseButtonProps & {
47
48
  fullWidth?: boolean;
48
49
  text?: string;
@@ -50,8 +51,9 @@ declare type ButtonProps = BaseButtonProps & {
50
51
  elementId?: string;
51
52
  loading?: boolean;
52
53
  isRichText?: boolean;
54
+ containerStyle?: CSSProperties;
53
55
  };
54
- declare const Button: ({ text, onClick, loading, disabled, variant, isRichText, fullWidth, elementId, link, }: ButtonProps) => JSX.Element | null;
56
+ declare const Button: ({ text: textProp, onClick, loading, disabled, variant, isRichText, fullWidth, elementId, link, containerStyle, children, size, }: ButtonProps) => JSX.Element | null;
55
57
 
56
58
  declare type TouchableOpacityProps = PropsWithChildren<{
57
59
  activeOpacity?: number;
@@ -181,7 +183,7 @@ declare type ImageProps = {
181
183
  declare const Image: styled_components.StyledComponent<"img", styled_components.DefaultTheme, ImageProps, never>;
182
184
  declare const BackgroundImage: styled_components.StyledComponent<"img", styled_components.DefaultTheme, ImageProps, never>;
183
185
 
184
- declare type LinkButtonProps = PropsWithChildren<{
186
+ declare type TextButtonProps = PropsWithChildren<{
185
187
  activeOpacity?: number;
186
188
  withoutOpacityEffect?: boolean;
187
189
  disabled?: boolean;
@@ -189,7 +191,7 @@ declare type LinkButtonProps = PropsWithChildren<{
189
191
  buttonLink?: string;
190
192
  elementId?: string;
191
193
  }>;
192
- declare const LinkButton: styled_components.StyledComponent<"div", styled_components.DefaultTheme, {
194
+ declare const TextButton: styled_components.StyledComponent<"div", styled_components.DefaultTheme, {
193
195
  activeOpacity?: number | undefined;
194
196
  withoutOpacityEffect?: boolean | undefined;
195
197
  disabled?: boolean | undefined;
@@ -537,7 +539,7 @@ declare type ColumnsProps = {
537
539
  declare type ColumnItem = {
538
540
  title?: string;
539
541
  mainContent?: string;
540
- button?: LinkButtonProps$1;
542
+ button?: TextButtonProps$1;
541
543
  icon: string;
542
544
  };
543
545
  declare const Columns: ({ columns, containerStyles, template }: ColumnsProps) => JSX.Element;
@@ -745,7 +747,7 @@ declare type LoginFields = {
745
747
  };
746
748
 
747
749
  declare type LoginFormProps = {
748
- fields: UIFields<LoginFields>;
750
+ fields: UIFields$2<LoginFields>;
749
751
  logoUrl: string;
750
752
  isLoading?: boolean;
751
753
  twoFactorAuthConfig?: {
@@ -1039,4 +1041,4 @@ declare type AnnotationsList = {
1039
1041
 
1040
1042
  declare const useMlrRichTextViewerContext: () => contexts_MlrRichTextViewerContext_MlrRichTextViewerContext.MlrRichTextViewerContextType;
1041
1043
 
1042
- export { AcquisitionForm, AcquisitionFormProps, Alert, AlertProps, AnnotationsList, AuthMethod, Avatar, AvatarDropdown, AvatarDropdownProps, AvatarProps, BackgroundImage, BaseButtonProps, Body, BodyProps, BottomNaVBarItemProps, BottomNavBarItem, BottomNavBarNavigation, BottomNavBarNavigationProps, BreakpointSizesTypes, Button, ButtonProps, COMMUNICATION_LINK_DATA_TEXT, COMMUNICATION_LINK_DATA_URL, COMMUNICATION_LINK_ELEMENT_ID, CaretIconWrapper, CheckBoxProps, Checkbox, CheckboxField, CheckboxFieldProps, Circle, CircleBoxProps, CircularIndicator, CircularIndicatorProps, CircularIndicatorStyledComponent, ColumnItem, Columns, ColumnsProps, Consent, ConsentProps, CustomValidation, CustomValidationProps, CustomValidationRule, DefaultTemplate, DefaultTemplateProps, Divider, DividerProps, Drawer, DynamicContentZone, DynamicContentZoneProps, DynamicElementProps, EmphasizedText, EmphasizedTextProps, FeedContent, FeedContentContainer, FeedContentContainerProps, FeedContentHeader, FeedContentHeaderProps, FeedTemplateKeys, FieldLabels, FieldLabelsProps, FieldMapper, FieldMapperProps, FieldRuleLabelTypes, FieldSection, FieldSectionProps, FieldTypes, FilteredFeedContentType, FontSizesTypes, Footer, FooterContactInfo, FooterLink, FooterProps, ForgotPasswordForm, ForgotPasswordFormProps, GoogleMap, GoogleMapProps, Header, HeaderProps, HeroImage, HeroImageAlignment, HeroImageProps, HeroImageTemplate, HeroSlider, HeroSliderProps, HeroSliderWrapper, HorizontalButtons, HorizontalButtonsField, HorizontalButtonsProps, HorizontalPadding, HorizontalPaddingProps, ISI, ISIProps, Icon, IconButton, IconButtonProps, IconNames, IconProps, Image, ImageProps, Input, InputField, InputFieldProps, InputFieldTypes, InputIconProps, InputProps, LinkButton, LinkButtonProps, LoginForm, LoginFormProps, MATRIX_MESSAGE_DATA_ID, MATRIX_MESSAGE_ELEMENT_ID, MapPosition, MenuItem, MenuItems, MenuItemsProps, MenuNavigation, MenuNavigationProps, MlrRichTextViewerContext, MlrRichTextViewerContextType, MlrRichTextViewerProvider, MlrRichTextViewerProviderProps, OrientationType, PdfDocument, PdfDocumentProps, ProcessTracker, ProcessTrackerProps, ProcessTrackerStatus, ProfileInformation, ProfileInformationProps, RadioButtonField, RadioButtonFieldProps, RadioButtonType, RadioButtons, RadioButtonsProps, RichTextEditorProps, RichTextViewer, Select, SelectField, SelectFieldProps, SelectableCardGroup, SelectableCardGroupProps, SetPasswordForm, SetPasswordFormProps, SetPasswordRuleValidation, SizesTypes, Spacer, SpacerProps, Spinner, Stepper, StepperProps, StyleWrapper, SubscribePanel, TabGroup, TabGroupProps, TextAlign, TextTypes, TextWrapper, TextWrapperProps, ThemeColors, ThemeColorsType, ThemeDevicesType, ThemeSizesType, ThemeTextType, Tooltip, TooltipProps, TouchableOpacity, TouchableOpacityProps, TwoFactorAuth, TwoFactorAuthProps, UICheckboxField, UIField, UIFields, UIInputField, UISelectField, ValidationTag, ValidationTagProps, ValidationTagStatus, VerticalPadding, Video, VideoProps, ZealTheme, ZealThemeProvider, acquisitionFormMockFields, defaultTheme, getFieldPlaceholder, getFieldsFromFieldSections, getInitialValuesFromFields, isFormValid, loginMockFields, profileInformationMockForm, sectionMockFields, setPasswordMockFields, showAcceptToastMessage, toast, toastStyles, useMediaQuery, useMlrRichTextViewerContext, useRequiredConsentsAcceptedValues, useStep };
1044
+ export { AcquisitionForm, AcquisitionFormProps, Alert, AlertProps, AnnotationsList, AuthMethod, Avatar, AvatarDropdown, AvatarDropdownProps, AvatarProps, BackgroundImage, BaseButtonProps, Body, BodyProps, BottomNaVBarItemProps, BottomNavBarItem, BottomNavBarNavigation, BottomNavBarNavigationProps, BreakpointSizesTypes, Button, ButtonProps, COMMUNICATION_LINK_DATA_TEXT, COMMUNICATION_LINK_DATA_URL, COMMUNICATION_LINK_ELEMENT_ID, CaretIconWrapper, CheckBoxProps, Checkbox, CheckboxField, CheckboxFieldProps, Circle, CircleBoxProps, CircularIndicator, CircularIndicatorProps, CircularIndicatorStyledComponent, ColumnItem, Columns, ColumnsProps, Consent, ConsentProps, CustomValidation, CustomValidationProps, CustomValidationRule, DefaultTemplate, DefaultTemplateProps, Divider, DividerProps, Drawer, DynamicContentZone, DynamicContentZoneProps, DynamicElementProps, EmphasizedText, EmphasizedTextProps, FeedContent, FeedContentContainer, FeedContentContainerProps, FeedContentHeader, FeedContentHeaderProps, FeedTemplateKeys, FieldLabels, FieldLabelsProps, FieldMapper, FieldMapperProps, FieldRuleLabelTypes, FieldSection, FieldSectionProps, FieldTypes, FilteredFeedContentType, FontSizesTypes, Footer, FooterContactInfo, FooterLink, FooterProps, ForgotPasswordForm, ForgotPasswordFormProps, GoogleMap, GoogleMapProps, Header, HeaderProps, HeroImage, HeroImageAlignment, HeroImageProps, HeroImageTemplate, HeroSlider, HeroSliderProps, HeroSliderWrapper, HorizontalButtons, HorizontalButtonsField, HorizontalButtonsProps, HorizontalPadding, HorizontalPaddingProps, ISI, ISIProps, Icon, IconButton, IconButtonProps, IconNames, IconProps, Image, ImageProps, Input, InputField, InputFieldProps, InputFieldTypes, InputIconProps, InputProps, LoginForm, LoginFormProps, MATRIX_MESSAGE_DATA_ID, MATRIX_MESSAGE_ELEMENT_ID, MapPosition, MenuItem, MenuItems, MenuItemsProps, MenuNavigation, MenuNavigationProps, MlrRichTextViewerContext, MlrRichTextViewerContextType, MlrRichTextViewerProvider, MlrRichTextViewerProviderProps, OrientationType, PdfDocument, PdfDocumentProps, ProcessTracker, ProcessTrackerProps, ProcessTrackerStatus, ProfileInformation, ProfileInformationProps, RadioButtonField, RadioButtonFieldProps, RadioButtonType, RadioButtons, RadioButtonsProps, RichTextEditorProps, RichTextViewer, Select, SelectField, SelectFieldProps, SelectableCardGroup, SelectableCardGroupProps, SetPasswordForm, SetPasswordFormProps, SetPasswordRuleValidation, SizesTypes, Spacer, SpacerProps, Spinner, Stepper, StepperProps, StyleWrapper, SubscribePanel, TabGroup, TabGroupProps, TextAlign, TextButton, TextButtonProps, TextTypes, TextWrapper, TextWrapperProps, ThemeColors, ThemeColorsType, ThemeDevicesType, ThemeSizesType, ThemeTextType, Tooltip, TooltipProps, TouchableOpacity, TouchableOpacityProps, TwoFactorAuth, TwoFactorAuthProps, UICheckboxField, UIField, UIFields, UIInputField, UISelectField, ValidationTag, ValidationTagProps, ValidationTagStatus, VerticalPadding, Video, VideoProps, ZealTheme, ZealThemeProvider, acquisitionFormMockFields, defaultTheme, getFieldPlaceholder, getFieldsFromFieldSections, getInitialValuesFromFields, isFormValid, loginMockFields, profileInformationMockForm, sectionMockFields, setPasswordMockFields, showAcceptToastMessage, toast, toastStyles, useMediaQuery, useMlrRichTextViewerContext, useRequiredConsentsAcceptedValues, useStep };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zealicsolutions/web-ui",
3
- "version": "0.2.58",
3
+ "version": "0.2.60",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+ssh://git@bitbucket.org/Zealic_Solutions/zeal-ui-web.git"