@npm_leadtech/legal-lib-components 5.14.6 → 5.14.8

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.
Files changed (23) hide show
  1. package/dist/src/components/atoms/DatePickerCustom/DatePickerCustom.js +2 -22
  2. package/dist/src/components/atoms/DatePickerCustom/DatePickerCustom.tsx +0 -24
  3. package/dist/src/components/atoms/DatePickerCustom/DatePickerCustomProps.types.d.ts +0 -1
  4. package/dist/src/components/atoms/DatePickerCustom/DatePickerCustomProps.types.ts +0 -1
  5. package/dist/src/components/atoms/DatePickerCustom/index.js.map +4 -4
  6. package/dist/src/components/atoms/TagRatafiaItem/TagRatafiaItem.styled.js +2 -0
  7. package/dist/src/components/atoms/TagRatafiaItem/TagRatafiaItem.styled.ts +2 -0
  8. package/dist/src/components/molecules/TagsRatafiaList/TagsRatafiaList.styled.js +2 -1
  9. package/dist/src/components/molecules/TagsRatafiaList/TagsRatafiaList.styled.ts +2 -1
  10. package/dist/src/components/sections/LayoutRatafiaSection/LayoutRatafiaSection.d.ts +4 -0
  11. package/dist/src/components/sections/LayoutRatafiaSection/LayoutRatafiaSection.js +11 -0
  12. package/dist/src/components/sections/LayoutRatafiaSection/LayoutRatafiaSection.styled.d.ts +1 -0
  13. package/dist/src/components/sections/LayoutRatafiaSection/LayoutRatafiaSection.styled.js +75 -0
  14. package/dist/src/components/sections/LayoutRatafiaSection/LayoutRatafiaSection.styled.ts +76 -0
  15. package/dist/src/components/sections/LayoutRatafiaSection/LayoutRatafiaSection.tsx +56 -0
  16. package/dist/src/components/sections/LayoutRatafiaSection/LayoutRatafiaSectionProps.types.d.ts +10 -0
  17. package/dist/src/components/sections/LayoutRatafiaSection/LayoutRatafiaSectionProps.types.js +1 -0
  18. package/dist/src/components/sections/LayoutRatafiaSection/LayoutRatafiaSectionProps.types.ts +11 -0
  19. package/dist/src/components/sections/LayoutRatafiaSection/index.d.ts +2 -0
  20. package/dist/src/components/sections/LayoutRatafiaSection/index.js +1 -0
  21. package/dist/src/components/sections/LayoutRatafiaSection/index.ts +2 -0
  22. package/dist/tsconfig.build.tsbuildinfo +1 -1
  23. package/package.json +3 -2
@@ -5,8 +5,7 @@ import { de } from 'date-fns/locale';
5
5
  import { DatePickerCustomStyled } from './DatePickerCustom.styled';
6
6
  // import './DatepickerPlugin.scss'
7
7
  registerLocale('de', de);
8
- const DatePickerCustom = ({ class: className, dateFormat = 'MM/dd/yyyy', isStartDate = false, isValidGroup = false, label, locale = 'en', name, onChange, relatedDate, isMobile, tooltip, type, validate = false, value }) => {
9
- const [event, setEvent] = useState();
8
+ const DatePickerCustom = ({ class: className, dateFormat = 'MM/dd/yyyy', isStartDate = false, isValidGroup = false, label, locale = 'en', name, onChange, relatedDate, tooltip, type, validate = false, value }) => {
10
9
  const [date, setDate] = useState(() => {
11
10
  return typeof value === 'string' && value !== '' ? new Date(value) : null;
12
11
  });
@@ -58,26 +57,7 @@ const DatePickerCustom = ({ class: className, dateFormat = 'MM/dd/yyyy', isStart
58
57
  monthName
59
58
  };
60
59
  });
61
- let propsForMobileDevices = {};
62
- if (isMobile) {
63
- propsForMobileDevices = {
64
- portalId: 'root-portal',
65
- withPortal: true,
66
- onFocus: (event) => {
67
- setEvent(event);
68
- event.target.blur();
69
- },
70
- onCalendarClose: () => {
71
- if (event) {
72
- const timmerID = setTimeout(() => {
73
- event.target.blur();
74
- clearTimeout(timmerID);
75
- }, 1);
76
- }
77
- }
78
- };
79
- }
80
- return (_jsxs(DatePickerCustomStyled, { className: classStyle, "data-qa": name, children: [TooltipObject, _jsx(DatePicker, { ...propsForMobileDevices, locale: locale, dateFormat: dateFormat, renderCustomHeader: ({ date, changeYear, changeMonth, decreaseMonth, increaseMonth, prevMonthButtonDisabled, nextMonthButtonDisabled }) => (_jsxs("div", { style: {
60
+ return (_jsxs(DatePickerCustomStyled, { className: classStyle, "data-qa": name, children: [TooltipObject, _jsx(DatePicker, { locale: locale, dateFormat: dateFormat, renderCustomHeader: ({ date, changeYear, changeMonth, decreaseMonth, increaseMonth, prevMonthButtonDisabled, nextMonthButtonDisabled }) => (_jsxs("div", { style: {
81
61
  margin: 10,
82
62
  display: 'flex',
83
63
  justifyContent: 'center'
@@ -18,13 +18,11 @@ const DatePickerCustom: FC<DatePickerCustomProps> = ({
18
18
  name,
19
19
  onChange,
20
20
  relatedDate,
21
- isMobile,
22
21
  tooltip,
23
22
  type,
24
23
  validate = false,
25
24
  value
26
25
  }): React.JSX.Element => {
27
- const [event, setEvent] = useState<React.ChangeEvent<HTMLInputElement>>()
28
26
  const [date, setDate] = useState(() => {
29
27
  return typeof value === 'string' && value !== '' ? new Date(value) : null
30
28
  })
@@ -92,32 +90,10 @@ const DatePickerCustom: FC<DatePickerCustomProps> = ({
92
90
  }
93
91
  })
94
92
 
95
- let propsForMobileDevices = {}
96
-
97
- if (isMobile) {
98
- propsForMobileDevices = {
99
- portalId: 'root-portal',
100
- withPortal: true,
101
- onFocus: (event) => {
102
- setEvent(event)
103
- event.target.blur()
104
- },
105
- onCalendarClose: () => {
106
- if (event) {
107
- const timmerID = setTimeout(() => {
108
- event.target.blur()
109
- clearTimeout(timmerID)
110
- }, 1)
111
- }
112
- }
113
- }
114
- }
115
-
116
93
  return (
117
94
  <DatePickerCustomStyled className={classStyle} data-qa={name}>
118
95
  {TooltipObject}
119
96
  <DatePicker
120
- {...propsForMobileDevices}
121
97
  locale={locale}
122
98
  dateFormat={dateFormat}
123
99
  renderCustomHeader={({
@@ -13,6 +13,5 @@ export interface DatePickerCustomProps {
13
13
  relatedDate?: Date;
14
14
  type?: string;
15
15
  dateFormat?: string;
16
- isMobile?: boolean;
17
16
  onChange?: (dateObject: any) => void;
18
17
  }
@@ -14,6 +14,5 @@ export interface DatePickerCustomProps {
14
14
  relatedDate?: Date
15
15
  type?: string
16
16
  dateFormat?: string
17
- isMobile?: boolean
18
17
  onChange?: (dateObject: any) => void
19
18
  }