techsbcn-storybook 2.0.1 → 2.0.3

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/README.md CHANGED
@@ -117,7 +117,7 @@ The library is built in three steps, wired together in the `build` script:
117
117
  - **Forms & validation**: React Hook Form 7, Yup 1, `@hookform/resolvers`
118
118
  - **Dates**: `@mui/x-date-pickers`, `dayjs`
119
119
  - **i18n**: `i18next`, `react-i18next`, `i18next-browser-languagedetector`
120
- - **Routing (form components)**: `react-router-dom` 7
120
+ - **Routing (form components)**: `react-router` 8
121
121
  - **Language & tooling**: TypeScript 6, ESLint 9 (flat config), Prettier 3, Jest 30, Storybook 10, tsup 8
122
122
 
123
123
  ## Publishing
@@ -1,26 +1,10 @@
1
1
  import React from 'react';
2
-
2
+ import { DatePickerProps } from '@mui/x-date-pickers';
3
3
  import { Dayjs } from 'dayjs';
4
- declare type CalendarPickerView = 'year' | 'day' | 'month';
5
- export interface DatePickerComponentProps {
6
- id?: string;
7
- label?: string;
8
- name?: string;
4
+ import { TextFieldComponentProps } from '../TextFieldComponent/TextFieldComponent';
5
+ export interface DatePickerComponentProps extends Omit<DatePickerProps, 'value' | 'onChange' | 'slotProps'> {
6
+ textField?: TextFieldComponentProps;
9
7
  value?: string | Dayjs | null;
10
- className?: string;
11
- inputFormat?: string;
12
- required?: boolean;
13
- disabled?: boolean;
14
- error?: boolean;
15
- startIcon?: React.ReactNode;
16
- fullWidth?: boolean;
17
- helperText?: string;
18
- inputRef?: React.Ref<any>;
19
- onChange: (value: any, context?: any) => void;
20
- noBorders?: boolean;
21
- maxDate?: any;
22
- minDate?: any;
23
- views?: CalendarPickerView[];
8
+ onChange: (value: Dayjs | null, context?: any) => void;
24
9
  }
25
10
  export declare const DatePickerComponent: React.FC<DatePickerComponentProps>;
26
- export {};
@@ -4,8 +4,8 @@ export declare const buildReactSelectStyles: (theme: Theme) => {
4
4
  control: (base: any, state: any) => any;
5
5
  menu: (base: any) => any;
6
6
  option: (base: any, state: any) => any;
7
- singleValue: (base: any) => any;
8
- multiValueLabel: (base: any) => any;
9
- placeholder: (base: any) => any;
10
- input: (base: any) => any;
7
+ singleValue: (base: any, state: any) => any;
8
+ multiValueLabel: (base: any, state: any) => any;
9
+ placeholder: (base: any, state: any) => any;
10
+ input: (base: any, state: any) => any;
11
11
  };
@@ -1,34 +1,23 @@
1
1
  import React from 'react';
2
- import { StandardTextFieldProps } from '@mui/material';
3
-
2
+ import { BaseTextFieldProps, TextFieldVariants } from '@mui/material';
4
3
  export type InputType = 'button' | 'checkbox' | 'color' | 'date' | 'datetime-local' | 'email' | 'file' | 'hidden' | 'image' | 'month' | 'number' | 'password' | 'radio' | 'range' | 'reset' | 'search' | 'submit' | 'tel' | 'text' | 'time' | 'url' | 'week';
5
- export interface TextFieldComponentProps extends StandardTextFieldProps {
6
- id?: string;
7
- label?: string;
8
- name?: string;
9
- value?: string | number;
10
- className?: string;
11
- type?: InputType;
12
- placeholder?: string;
13
- required?: boolean;
14
- disabled?: boolean;
15
- minNumber?: number;
16
- maxNumber?: number;
17
- error?: boolean;
4
+ export interface TextFieldComponentProps extends BaseTextFieldProps {
18
5
  startIcon?: React.ReactNode;
19
6
  endIcon?: React.ReactNode;
20
- fullWidth?: boolean;
21
- helperText?: string;
7
+ noBorders?: boolean;
8
+ disableUnderline?: boolean;
9
+ shrink?: boolean;
22
10
  textFieldRef?: any;
23
- inputRef?: React.Ref<any>;
24
- autoComplete?: string;
25
- multiline?: boolean;
26
- rows?: number;
11
+ minNumber?: number;
12
+ maxNumber?: number;
27
13
  maxLength?: number;
14
+ step?: number | string;
15
+ type?: InputType;
16
+ value?: string | number;
28
17
  defaultValue?: string | number;
18
+ inputRef?: React.Ref<any>;
29
19
  onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
30
20
  onKeyUp?: (event: React.KeyboardEvent<HTMLInputElement>) => void;
31
- step?: number | string;
32
- noBorders?: boolean;
21
+ variant?: TextFieldVariants;
33
22
  }
34
23
  export declare const TextFieldComponent: React.FC<TextFieldComponentProps>;
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+
3
+ interface SplitLayoutProps {
4
+ imgUrl?: string;
5
+ contentBackgroundColor?: string;
6
+ children?: React.ReactNode;
7
+ }
8
+ export declare const SplitLayout: React.FC<SplitLayoutProps>;
9
+ export {};
@@ -1,5 +1,4 @@
1
1
  import React from 'react';
2
-
3
2
  interface TabsComponentProps {
4
3
  tabActive: number;
5
4
  tabs: TabLabel[];
@@ -0,0 +1,7 @@
1
+ export interface Session {
2
+ nameidentifier: string;
3
+ role: string[];
4
+ }
5
+ export declare const GetSession: () => Session | null;
6
+ export declare const SaveSession: (jwt: string) => void;
7
+ export declare const ClearSession: () => void;
@@ -1,3 +1,4 @@
1
+ export * from './AuthHelper';
1
2
  export * from './CheckPermission';
2
3
  export * from './GroupBy';
3
4
  export * from './FileDownloader';
package/dist/index.d.ts CHANGED
@@ -4,6 +4,7 @@ export * from './components/tables/SearchComponent/SearchComponent';
4
4
  export * from './components/tables/TableComponent/TableComponent';
5
5
  export * from './components/tables/SimpleTableComponent/SimpleTableComponent';
6
6
  export * from './components/layouts/MainLayoutSimple/MainLayoutSimple';
7
+ export * from './components/layouts/SplitLayout/SplitLayout';
7
8
  export * from './components/navigation/VerticalNav/VerticalNav';
8
9
  export * from './components/navigation/components/UserInfo';
9
10
  export * from './components/layouts/Standard/AppSidebar/AppSidebar';