design-react-kit 5.6.0 → 5.7.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/CHANGELOG.md +27 -0
- package/dist/Accordion/AccordionBody.cjs +1 -1
- package/dist/Accordion/AccordionBody.cjs.map +1 -1
- package/dist/Accordion/AccordionBody.js +31 -21
- package/dist/Accordion/AccordionBody.js.map +1 -1
- package/dist/Accordion/AccordionHeader.cjs +1 -1
- package/dist/Accordion/AccordionHeader.cjs.map +1 -1
- package/dist/Accordion/AccordionHeader.js +1 -1
- package/dist/Accordion/AccordionHeader.js.map +1 -1
- package/dist/Autocomplete/Autocomplete.cjs +1 -3
- package/dist/Autocomplete/Autocomplete.cjs.map +1 -1
- package/dist/Autocomplete/Autocomplete.js +27 -4
- package/dist/Autocomplete/Autocomplete.js.map +1 -1
- package/dist/Carousel/Carousel.cjs +2 -0
- package/dist/Carousel/Carousel.cjs.map +1 -0
- package/dist/Carousel/Carousel.js +193 -0
- package/dist/Carousel/Carousel.js.map +1 -0
- package/dist/Carousel/CarouselSlide.cjs +2 -0
- package/dist/Carousel/CarouselSlide.cjs.map +1 -0
- package/dist/Carousel/CarouselSlide.js +8 -0
- package/dist/Carousel/CarouselSlide.js.map +1 -0
- package/dist/Input/Input.cjs +1 -1
- package/dist/Input/Input.cjs.map +1 -1
- package/dist/Input/Input.js +3 -9
- package/dist/Input/Input.js.map +1 -1
- package/dist/Input/TextArea.cjs +1 -1
- package/dist/Input/TextArea.cjs.map +1 -1
- package/dist/Input/utils.cjs +1 -1
- package/dist/Input/utils.cjs.map +1 -1
- package/dist/Input/utils.js +2 -4
- package/dist/Input/utils.js.map +1 -1
- package/dist/Rating/Rating.cjs +1 -1
- package/dist/Rating/Rating.cjs.map +1 -1
- package/dist/Transfer/BacktransferButton.cjs +2 -0
- package/dist/Transfer/BacktransferButton.cjs.map +1 -0
- package/dist/Transfer/BacktransferButton.js +20 -0
- package/dist/Transfer/BacktransferButton.js.map +1 -0
- package/dist/Transfer/Item.cjs +2 -0
- package/dist/Transfer/Item.cjs.map +1 -0
- package/dist/Transfer/Item.js +15 -0
- package/dist/Transfer/Item.js.map +1 -0
- package/dist/Transfer/ResetButton.cjs +2 -0
- package/dist/Transfer/ResetButton.cjs.map +1 -0
- package/dist/Transfer/ResetButton.js +16 -0
- package/dist/Transfer/ResetButton.js.map +1 -0
- package/dist/Transfer/SelectAllCheckbox.cjs +2 -0
- package/dist/Transfer/SelectAllCheckbox.cjs.map +1 -0
- package/dist/Transfer/SelectAllCheckbox.js +11 -0
- package/dist/Transfer/SelectAllCheckbox.js.map +1 -0
- package/dist/Transfer/Source.cjs +2 -0
- package/dist/Transfer/Source.cjs.map +1 -0
- package/dist/Transfer/Source.js +61 -0
- package/dist/Transfer/Source.js.map +1 -0
- package/dist/Transfer/Target.cjs +2 -0
- package/dist/Transfer/Target.cjs.map +1 -0
- package/dist/Transfer/Target.js +60 -0
- package/dist/Transfer/Target.js.map +1 -0
- package/dist/Transfer/Transfer.cjs +2 -0
- package/dist/Transfer/Transfer.cjs.map +1 -0
- package/dist/Transfer/Transfer.js +21 -0
- package/dist/Transfer/Transfer.js.map +1 -0
- package/dist/Transfer/TransferButton.cjs +2 -0
- package/dist/Transfer/TransferButton.cjs.map +1 -0
- package/dist/Transfer/TransferButton.js +20 -0
- package/dist/Transfer/TransferButton.js.map +1 -0
- package/dist/Transfer/useTransferContext.cjs +2 -0
- package/dist/Transfer/useTransferContext.cjs.map +1 -0
- package/dist/Transfer/useTransferContext.js +63 -0
- package/dist/Transfer/useTransferContext.js.map +1 -0
- package/dist/Video/Video.cjs +2 -0
- package/dist/Video/Video.cjs.map +1 -0
- package/dist/Video/Video.js +99 -0
- package/dist/Video/Video.js.map +1 -0
- package/dist/index.cjs +1 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +4 -0
- package/dist/index.js.map +1 -1
- package/dist/types/Autocomplete/Autocomplete.d.ts +10 -5
- package/dist/types/Carousel/Carousel.d.ts +7 -0
- package/dist/types/Carousel/CarouselSlide.d.ts +2 -0
- package/dist/types/Input/Input.d.ts +2 -4
- package/dist/types/Input/utils.d.ts +1 -1
- package/dist/types/Transfer/BacktransferButton.d.ts +3 -0
- package/dist/types/Transfer/Item.d.ts +12 -0
- package/dist/types/Transfer/ResetButton.d.ts +3 -0
- package/dist/types/Transfer/SelectAllCheckbox.d.ts +10 -0
- package/dist/types/Transfer/Source.d.ts +9 -0
- package/dist/types/Transfer/Target.d.ts +9 -0
- package/dist/types/Transfer/Transfer.d.ts +40 -0
- package/dist/types/Transfer/TransferButton.d.ts +3 -0
- package/dist/types/Transfer/useTransferContext.d.ts +49 -0
- package/dist/types/Video/Video.d.ts +58 -0
- package/dist/types/index.d.ts +6 -0
- package/package.json +6 -3
- package/src/Accordion/AccordionBody.tsx +32 -22
- package/src/Accordion/AccordionHeader.tsx +0 -1
- package/src/Autocomplete/Autocomplete.tsx +69 -18
- package/src/Carousel/Carousel.tsx +210 -0
- package/src/Carousel/CarouselSlide.tsx +14 -0
- package/src/Input/Input.tsx +10 -19
- package/src/Input/utils.tsx +3 -5
- package/src/Transfer/BacktransferButton.tsx +33 -0
- package/src/Transfer/Item.tsx +33 -0
- package/src/Transfer/ResetButton.tsx +28 -0
- package/src/Transfer/SelectAllCheckbox.tsx +30 -0
- package/src/Transfer/Source.tsx +89 -0
- package/src/Transfer/Target.tsx +87 -0
- package/src/Transfer/Transfer.tsx +31 -0
- package/src/Transfer/TransferButton.tsx +33 -0
- package/src/Transfer/useTransferContext.tsx +110 -0
- package/src/Video/Video.tsx +205 -0
- package/src/index.ts +6 -0
package/dist/index.js
CHANGED
|
@@ -33,6 +33,8 @@ export { CardTag } from './Card/CardTag';
|
|
|
33
33
|
export { CardTagsHeader } from './Card/CardTagsHeader';
|
|
34
34
|
export { CardText } from './Card/CardText';
|
|
35
35
|
export { CardTitle } from './Card/CardTitle';
|
|
36
|
+
export { Carousel } from './Carousel/Carousel';
|
|
37
|
+
export { CarouselSlide } from './Carousel/CarouselSlide';
|
|
36
38
|
export { Chip } from './Chips/Chip';
|
|
37
39
|
export { ChipLabel } from './Chips/ChipLabel';
|
|
38
40
|
export { Collapse } from './Collapse/Collapse';
|
|
@@ -100,5 +102,7 @@ export { Toggle } from './Toggle/Toggle';
|
|
|
100
102
|
export { Toolbar } from './Toolbar/Toolbar';
|
|
101
103
|
export { ToolbarDividerItem } from './Toolbar/ToolbarDividerItem';
|
|
102
104
|
export { ToolbarItem } from './Toolbar/ToolbarItem';
|
|
105
|
+
export { Transfer } from './Transfer/Transfer';
|
|
106
|
+
export { Video } from './Video/Video';
|
|
103
107
|
import './track-focus.js';
|
|
104
108
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,cAAc,EACd,WAAW,EACX,aAAa,EACb,WAAW,EACX,QAAQ,EACR,UAAU,EACV,SAAS,EACT,UAAU,EACV,OAAO,EACP,cAAc,EACd,QAAQ,EACR,YAAY,EACZ,GAAG,EACH,SAAS,EACT,IAAI,EACJ,IAAI,EACJ,YAAY,EACZ,SAAS,EACT,QAAQ,EACR,UAAU,EACV,cAAc,EACd,KAAK,EACL,SAAS,EACT,aAAa,EACb,oBAAoB,EACpB,iBAAiB,EACjB,KAAK,EACL,OAAO,EACP,OAAO,EACP,MAAM,EACN,WAAW,EACX,aAAa,EACb,cAAc,IAAI,SAAS,EAC3B,cAAc,IAAI,SAAS,EAC3B,OAAO,EACP,WAAW,EACX,aAAa,EACb,GAAG,EACH,KAAK,EACL,OAAO,EACP,iBAAiB,EACjB,oBAAoB,EACpB,mBAAmB,EACnB,IAAI,EACL,MAAM,YAAY,CAAC;AAEpB,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AACpE,OAAO,EAAE,YAAY,EAAE,MAAM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E,WAAW,EAAE,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AACtD,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACzC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,kBAAkB,EAAE,MAAM,8BAA8B,CAAC;AAClE,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAC/C,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAgKrC,OAAO,kBAAkB,CAAC"}
|
|
@@ -1,18 +1,23 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
2
|
export interface AutocompleteAttributes {
|
|
3
3
|
/** Identificativo */
|
|
4
|
-
id
|
|
4
|
+
id: string;
|
|
5
|
+
/** Label */
|
|
6
|
+
label: string;
|
|
7
|
+
/** Valori all'interno della select */
|
|
8
|
+
source: (query: string, syncResults: () => void) => void;
|
|
5
9
|
/** Valori chiave - valore all'interno della select */
|
|
6
|
-
|
|
7
|
-
value: string;
|
|
8
|
-
label: string;
|
|
9
|
-
}[];
|
|
10
|
+
onConfirm?: (value: string) => void;
|
|
10
11
|
/** Placeholder (default: ``) */
|
|
11
12
|
placeholder?: string;
|
|
12
13
|
/** Valore di default (default: ``) */
|
|
13
14
|
defaultValue?: string;
|
|
14
15
|
/** Modalità display menu (default: `inline`) */
|
|
15
16
|
displayMenu?: string;
|
|
17
|
+
/** Utilizzare per mostrare il successo nella validazione del valore nel campo Input */
|
|
18
|
+
valid?: boolean;
|
|
19
|
+
/** Testo di validazione per l'elemento del moduleo form. */
|
|
20
|
+
validationText?: string;
|
|
16
21
|
/** Funzione ritornante stringa in caso di nessun risultato */
|
|
17
22
|
tNoResults?: () => string;
|
|
18
23
|
/** Funzione ritornante stringa di suggerimento */
|
|
@@ -15,7 +15,7 @@ export interface InputProps extends InputHTMLAttributes<HTMLInputElement> {
|
|
|
15
15
|
decrementLabel?: string | ReactNode;
|
|
16
16
|
/** Testo di esempio da utilizzare per il campo. */
|
|
17
17
|
placeholder?: string;
|
|
18
|
-
/** Testo di validazione per l'elemento del
|
|
18
|
+
/** Testo di validazione per l'elemento del modulo form. */
|
|
19
19
|
validationText?: string;
|
|
20
20
|
/** Testo di aiuto per l'elemento del moduleo form. Richiede che il componente `Input` abbia la prop `id` impostata. */
|
|
21
21
|
infoText?: string;
|
|
@@ -30,8 +30,6 @@ export interface InputProps extends InputHTMLAttributes<HTMLInputElement> {
|
|
|
30
30
|
innerRef?: Ref<HTMLInputElement>;
|
|
31
31
|
/** Utilizzare per mostrare testo statico non modificabile. */
|
|
32
32
|
plaintext?: boolean;
|
|
33
|
-
/** Utilizzare per mostrare un elemento addon a fianco (prima o dopo) il campo input all'interno del componente */
|
|
34
|
-
addon?: boolean;
|
|
35
33
|
/** Utilizzare per mostrare un elemento un simbolo attivando la proprietà addon nel campo input all'interno del componente */
|
|
36
34
|
addonText?: string;
|
|
37
35
|
/** Oggetto contenente la nuova mappatura per le classi CSS. */
|
|
@@ -64,5 +62,5 @@ export interface InputProps extends InputHTMLAttributes<HTMLInputElement> {
|
|
|
64
62
|
iconLeft?: ReactNode;
|
|
65
63
|
testId?: string;
|
|
66
64
|
}
|
|
67
|
-
export declare const Input: ({ id, className, cssModule, type, tag,
|
|
65
|
+
export declare const Input: ({ id, className, cssModule, type, tag, addonText, static: staticInput, plaintext, innerRef, label, incrementLabel, decrementLabel, validationText, infoText, placeholder, normalized, value, wrapperClass: originalWrapperClassOld, wrapperClassName: originalWrapperClass, size, testId, noWrapper, hasButtonRight, buttonRight, hasIconLeft, iconLeft, ...attributes }: InputProps) => React.JSX.Element;
|
|
68
66
|
export {};
|
|
@@ -4,7 +4,7 @@ type ValidationProps = Pick<InputProps, 'valid'>;
|
|
|
4
4
|
type TypeProps = Pick<InputProps, 'plaintext' | 'type'> & {
|
|
5
5
|
staticInput?: boolean;
|
|
6
6
|
};
|
|
7
|
-
type FormControlProps = Pick<InputProps, '
|
|
7
|
+
type FormControlProps = Pick<InputProps, 'normalized'> & TypeProps;
|
|
8
8
|
export declare function getFormControlClass(props: FormControlProps, cssModule?: CSSModule): string;
|
|
9
9
|
export declare function getValidationTextControlClass({ valid }: ValidationProps, cssModule?: CSSModule): string;
|
|
10
10
|
export declare function getTag({ tag, plaintext, staticInput, type }: Pick<InputProps, 'tag'> & TypeProps): import("react").ElementType;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
declare const Item: ({ id, children }: {
|
|
3
|
+
id: string;
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
}) => React.JSX.Element;
|
|
6
|
+
declare const InternalItem: ({ id, checked, children, onChange }: {
|
|
7
|
+
id: string;
|
|
8
|
+
checked?: boolean;
|
|
9
|
+
children: React.ReactNode;
|
|
10
|
+
onChange?: React.ChangeEventHandler<HTMLInputElement>;
|
|
11
|
+
}) => React.JSX.Element;
|
|
12
|
+
export { InternalItem, Item };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
declare const SelectAllCheckbox: ({ className, description, checked, id, onChange, children }: {
|
|
3
|
+
className?: string;
|
|
4
|
+
id: string;
|
|
5
|
+
checked?: boolean;
|
|
6
|
+
onChange: React.ChangeEventHandler<HTMLInputElement>;
|
|
7
|
+
children: React.ReactNode;
|
|
8
|
+
description?: string;
|
|
9
|
+
}) => React.JSX.Element;
|
|
10
|
+
export { SelectAllCheckbox };
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
declare const Transfer: {
|
|
3
|
+
({ children }: {
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
}): React.JSX.Element;
|
|
6
|
+
Source: React.FC<{
|
|
7
|
+
children?: React.ReactNode;
|
|
8
|
+
}> & {
|
|
9
|
+
Header: React.FC<{
|
|
10
|
+
children?: React.ReactNode;
|
|
11
|
+
}>;
|
|
12
|
+
};
|
|
13
|
+
Target: React.FC<{
|
|
14
|
+
children?: React.ReactNode;
|
|
15
|
+
}> & {
|
|
16
|
+
Header: React.FC<{
|
|
17
|
+
children?: React.ReactNode;
|
|
18
|
+
}>;
|
|
19
|
+
};
|
|
20
|
+
Item: ({ id, children }: {
|
|
21
|
+
id: string;
|
|
22
|
+
children: React.ReactNode;
|
|
23
|
+
}) => React.JSX.Element;
|
|
24
|
+
TransferButton: () => React.JSX.Element;
|
|
25
|
+
BacktransferButton: () => React.JSX.Element;
|
|
26
|
+
ResetButton: () => React.JSX.Element;
|
|
27
|
+
useTransfer: () => {
|
|
28
|
+
source: {
|
|
29
|
+
checked: boolean;
|
|
30
|
+
id: string;
|
|
31
|
+
content: React.ReactNode;
|
|
32
|
+
}[];
|
|
33
|
+
target: {
|
|
34
|
+
checked: boolean;
|
|
35
|
+
id: string;
|
|
36
|
+
content: React.ReactNode;
|
|
37
|
+
}[];
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
export { Transfer };
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
interface TransferContextType {
|
|
3
|
+
sourceItems: {
|
|
4
|
+
id: string;
|
|
5
|
+
content: React.ReactNode;
|
|
6
|
+
}[];
|
|
7
|
+
targetItems: {
|
|
8
|
+
id: string;
|
|
9
|
+
content: React.ReactNode;
|
|
10
|
+
}[];
|
|
11
|
+
sourceCandidates: string[];
|
|
12
|
+
targetCandidates: string[];
|
|
13
|
+
setSourceItems: ({ items, setOriginals }: {
|
|
14
|
+
items: {
|
|
15
|
+
id: string;
|
|
16
|
+
content: React.ReactNode;
|
|
17
|
+
}[];
|
|
18
|
+
setOriginals?: boolean;
|
|
19
|
+
}) => void;
|
|
20
|
+
setTargetItems: ({ items, setOriginals }: {
|
|
21
|
+
items: {
|
|
22
|
+
id: string;
|
|
23
|
+
content: React.ReactNode;
|
|
24
|
+
}[];
|
|
25
|
+
setOriginals?: boolean;
|
|
26
|
+
}) => void;
|
|
27
|
+
setSourceCandidates: (items: string[]) => void;
|
|
28
|
+
setTargetCandidates: (items: string[]) => void;
|
|
29
|
+
isChanged: boolean;
|
|
30
|
+
reset: () => void;
|
|
31
|
+
}
|
|
32
|
+
export declare const TransferContext: React.Context<TransferContextType>;
|
|
33
|
+
export declare const useTransferContext: () => TransferContextType;
|
|
34
|
+
export declare const TransferContextProvider: ({ children }: {
|
|
35
|
+
children: React.ReactNode;
|
|
36
|
+
}) => React.JSX.Element;
|
|
37
|
+
export declare const useTransfer: () => {
|
|
38
|
+
source: {
|
|
39
|
+
checked: boolean;
|
|
40
|
+
id: string;
|
|
41
|
+
content: React.ReactNode;
|
|
42
|
+
}[];
|
|
43
|
+
target: {
|
|
44
|
+
checked: boolean;
|
|
45
|
+
id: string;
|
|
46
|
+
content: React.ReactNode;
|
|
47
|
+
}[];
|
|
48
|
+
};
|
|
49
|
+
export {};
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
export interface VideoSource {
|
|
3
|
+
/** Sorgente del video */
|
|
4
|
+
src: string;
|
|
5
|
+
/** Tipo della sorgente video */
|
|
6
|
+
type: string;
|
|
7
|
+
}
|
|
8
|
+
export interface VideoTrackSource {
|
|
9
|
+
/** Tipologia di traccia audio */
|
|
10
|
+
kind: string;
|
|
11
|
+
/** Sorgente della traccia audio */
|
|
12
|
+
src: string;
|
|
13
|
+
/** Lingua della traccia audio */
|
|
14
|
+
srcLang: string;
|
|
15
|
+
/** Label della traccia audio */
|
|
16
|
+
label: string;
|
|
17
|
+
/** Setta la traccia audio come default */
|
|
18
|
+
isDefault?: boolean;
|
|
19
|
+
}
|
|
20
|
+
export interface VideoYouTube {
|
|
21
|
+
/** Url del video YouTube */
|
|
22
|
+
url: string;
|
|
23
|
+
/** Attiva o meno il disclaimer */
|
|
24
|
+
hasDisclaimer?: boolean;
|
|
25
|
+
/** Testo del disclaimer */
|
|
26
|
+
disclaimerText?: string;
|
|
27
|
+
/** Chiave del disclaimer come preferenza */
|
|
28
|
+
disclaimerKey?: string;
|
|
29
|
+
}
|
|
30
|
+
export interface VideoProps {
|
|
31
|
+
/** Id del componente Video */
|
|
32
|
+
id: string;
|
|
33
|
+
/** Sorgenti del video */
|
|
34
|
+
sources?: Array<VideoSource>;
|
|
35
|
+
/** Testo della trascrizione */
|
|
36
|
+
transcription?: string;
|
|
37
|
+
/** Label dell'accordion della trascrizione */
|
|
38
|
+
transcriptionLabel?: string;
|
|
39
|
+
/** Array delle tracce */
|
|
40
|
+
tracks?: Array<VideoTrackSource>;
|
|
41
|
+
/** Url del poster */
|
|
42
|
+
poster?: string;
|
|
43
|
+
/** Attiva o meno i controlli */
|
|
44
|
+
controls?: boolean;
|
|
45
|
+
/** Attiva o meno l'autoplay */
|
|
46
|
+
autoPlay?: boolean;
|
|
47
|
+
/** Attiva o meno il loop del video */
|
|
48
|
+
loop?: boolean;
|
|
49
|
+
/** Modalità visualizzazione fluida */
|
|
50
|
+
fluid?: boolean;
|
|
51
|
+
/** Video YouTube */
|
|
52
|
+
youtube?: VideoYouTube;
|
|
53
|
+
/** Label del pulsante di accettazione */
|
|
54
|
+
acceptLabel?: string;
|
|
55
|
+
/** Label della checkbox per ricordare la scelta di accettazione */
|
|
56
|
+
rememberLabel?: string;
|
|
57
|
+
}
|
|
58
|
+
export declare const Video: FC<VideoProps>;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -33,6 +33,8 @@ export { CardTag } from './Card/CardTag';
|
|
|
33
33
|
export { CardTagsHeader } from './Card/CardTagsHeader';
|
|
34
34
|
export { CardText } from './Card/CardText';
|
|
35
35
|
export { CardTitle } from './Card/CardTitle';
|
|
36
|
+
export { Carousel } from './Carousel/Carousel';
|
|
37
|
+
export { CarouselSlide } from './Carousel/CarouselSlide';
|
|
36
38
|
export { Chip } from './Chips/Chip';
|
|
37
39
|
export { ChipLabel } from './Chips/ChipLabel';
|
|
38
40
|
export { Collapse } from './Collapse/Collapse';
|
|
@@ -100,6 +102,8 @@ export { Toggle } from './Toggle/Toggle';
|
|
|
100
102
|
export { Toolbar } from './Toolbar/Toolbar';
|
|
101
103
|
export { ToolbarDividerItem } from './Toolbar/ToolbarDividerItem';
|
|
102
104
|
export { ToolbarItem } from './Toolbar/ToolbarItem';
|
|
105
|
+
export { Transfer } from './Transfer/Transfer';
|
|
106
|
+
export { Video } from './Video/Video';
|
|
103
107
|
export type { AccordionProps } from './Accordion/Accordion';
|
|
104
108
|
export type { AccordionBodyProps } from './Accordion/AccordionBody';
|
|
105
109
|
export type { AccordionHeaderProps } from './Accordion/AccordionHeader';
|
|
@@ -129,6 +133,7 @@ export type { CardTagProps } from './Card/CardTag';
|
|
|
129
133
|
export type { CardTagsHeaderProps } from './Card/CardTagsHeader';
|
|
130
134
|
export type { CardTextProps } from './Card/CardText';
|
|
131
135
|
export type { CardTitleProps } from './Card/CardTitle';
|
|
136
|
+
export type { CarouselProps } from './Carousel/Carousel';
|
|
132
137
|
export type { ChipProps } from './Chips/Chip';
|
|
133
138
|
export type { ChipLabelProps } from './Chips/ChipLabel';
|
|
134
139
|
export type { DimmerProps } from './Dimmer/Dimmer';
|
|
@@ -193,6 +198,7 @@ export type { TimelineProps } from './Timeline/TimelineWrapper';
|
|
|
193
198
|
export type { ToggleProps } from './Toggle/Toggle';
|
|
194
199
|
export type { ToolbarProps } from './Toolbar/Toolbar';
|
|
195
200
|
export type { ToolbarItemBadge, ToolbarItemProps } from './Toolbar/ToolbarItem';
|
|
201
|
+
export type { VideoProps, VideoYouTube, VideoSource, VideoTrackSource } from "./Video/Video";
|
|
196
202
|
export type { BreadcrumbItemProps, ButtonDropdownProps, ButtonGroupProps, ButtonToolbarProps, CardColumnsProps, CardDeckProps, CardFooterProps, CardGroupProps, CardHeaderProps, CardImgOverlayProps, CardImgProps, CardLinkProps, CardSubtitleProps, ColProps, ContainerProps, FadeProps, FormFeedbackProps, FormGroupProps, FormProps, FormTextProps, InputGroupProps, InputGroupTextProps, LabelProps, ListGroupItemHeadingProps, ListGroupItemProps, ListGroupItemTextProps, ListGroupProps, MediaProps, NavItemProps, NavLinkProps, NavbarBrandProps, NavbarProps, NavbarTogglerProps, PaginationItem as PagerItemProps, PaginationLink as PagerLinkProps, PopoverBodyProps, PopoverHeaderProps, PopoverProps, RowProps, TableProps, TooltipProps, UncontrolledAlertProps, UncontrolledCollapseProps, UncontrolledTooltipProps } from 'reactstrap';
|
|
197
203
|
export type { TabContainerProps, TabContentProps, TabPaneProps } from 'react-bootstrap';
|
|
198
204
|
import './track-focus.js';
|
package/package.json
CHANGED
|
@@ -19,12 +19,13 @@
|
|
|
19
19
|
"Sabatino Galasso",
|
|
20
20
|
"Andrea Stagi",
|
|
21
21
|
"Federico Turbino",
|
|
22
|
-
"Nicola Squartini"
|
|
22
|
+
"Nicola Squartini",
|
|
23
|
+
"Davide Bizzi"
|
|
23
24
|
],
|
|
24
25
|
"bugs": {
|
|
25
26
|
"url": "https://github.com/italia/design-react-kit/issues"
|
|
26
27
|
},
|
|
27
|
-
"version": "5.
|
|
28
|
+
"version": "5.7.0",
|
|
28
29
|
"license": "BSD-3",
|
|
29
30
|
"type": "module",
|
|
30
31
|
"module": "./dist/index.js",
|
|
@@ -107,7 +108,7 @@
|
|
|
107
108
|
"@types/react-bootstrap": "^0.32.37",
|
|
108
109
|
"@types/react-dom": "^18.2.24",
|
|
109
110
|
"@types/react-transition-group": "^4.4.10",
|
|
110
|
-
"bootstrap-italia": "^2.
|
|
111
|
+
"bootstrap-italia": "^2.14.0",
|
|
111
112
|
"browserslist-config-design-italia": "^1.0.0",
|
|
112
113
|
"eslint": "^9.10.0",
|
|
113
114
|
"eslint-plugin-mdx": "^3.1.5",
|
|
@@ -134,6 +135,8 @@
|
|
|
134
135
|
"vite": "^5.2.7"
|
|
135
136
|
},
|
|
136
137
|
"dependencies": {
|
|
138
|
+
"@splidejs/react-splide": "^0.7.12",
|
|
139
|
+
"accessible-autocomplete": "^3.0.1",
|
|
137
140
|
"classnames": "^2.3.1",
|
|
138
141
|
"is-number": "^7.0.0",
|
|
139
142
|
"react-bootstrap": "^2.10.6",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import classNames from 'classnames';
|
|
2
|
-
import React, { ElementType, PropsWithChildren, useCallback, useState } from 'react';
|
|
2
|
+
import React, { ElementType, PropsWithChildren, useCallback, useRef, useState } from 'react';
|
|
3
3
|
import { Transition } from 'react-transition-group';
|
|
4
4
|
import type { TransitionProps } from 'react-transition-group/Transition';
|
|
5
5
|
import { TransitionTimeouts, TransitionsKeys } from '../transitions';
|
|
@@ -39,43 +39,53 @@ export const AccordionBody = ({
|
|
|
39
39
|
...attributes
|
|
40
40
|
}: PropsWithChildren<AccordionBodyProps>) => {
|
|
41
41
|
const [height, setHeight] = useState<null | number>(null);
|
|
42
|
-
|
|
42
|
+
const nodeRef = useRef<HTMLElement>(null);
|
|
43
43
|
const onEntering = useCallback(
|
|
44
|
-
(
|
|
45
|
-
|
|
46
|
-
|
|
44
|
+
(isAppearing: boolean) => {
|
|
45
|
+
if (nodeRef.current) {
|
|
46
|
+
setHeight(getHeight(nodeRef.current));
|
|
47
|
+
attributes.onEntering?.(nodeRef.current, isAppearing);
|
|
48
|
+
}
|
|
47
49
|
},
|
|
48
50
|
[attributes.onEntering]
|
|
49
51
|
);
|
|
50
52
|
const onEntered = useCallback(
|
|
51
|
-
(
|
|
53
|
+
(isAppearing: boolean) => {
|
|
52
54
|
setHeight(null);
|
|
53
|
-
|
|
55
|
+
if (nodeRef.current) {
|
|
56
|
+
attributes.onEntered?.(nodeRef.current, isAppearing);
|
|
57
|
+
}
|
|
54
58
|
},
|
|
55
59
|
[attributes.onEntered]
|
|
56
60
|
);
|
|
57
61
|
const onExit = useCallback(
|
|
58
|
-
(
|
|
59
|
-
|
|
60
|
-
|
|
62
|
+
() => {
|
|
63
|
+
if (nodeRef.current) {
|
|
64
|
+
setHeight(getHeight(nodeRef.current));
|
|
65
|
+
attributes.onExit?.(nodeRef.current);
|
|
66
|
+
}
|
|
61
67
|
},
|
|
62
68
|
[attributes.onExit]
|
|
63
69
|
);
|
|
64
70
|
const onExiting = useCallback(
|
|
65
|
-
(
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
71
|
+
() => {
|
|
72
|
+
if (nodeRef.current) {
|
|
73
|
+
// getting this variable triggers a reflow
|
|
74
|
+
// @ts-expect-error variabile non usata
|
|
75
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
76
|
+
const _unused = nodeRef.current.offsetHeight;
|
|
77
|
+
setHeight(0);
|
|
78
|
+
attributes.onExiting?.(nodeRef.current);
|
|
79
|
+
}
|
|
72
80
|
},
|
|
73
81
|
[attributes.onExiting]
|
|
74
82
|
);
|
|
75
83
|
const onExited = useCallback(
|
|
76
|
-
(
|
|
84
|
+
() => {
|
|
77
85
|
setHeight(null);
|
|
78
|
-
|
|
86
|
+
if (nodeRef.current) {
|
|
87
|
+
attributes.onExited?.(nodeRef.current);
|
|
88
|
+
}
|
|
79
89
|
},
|
|
80
90
|
[attributes.onExited]
|
|
81
91
|
);
|
|
@@ -86,7 +96,7 @@ export const AccordionBody = ({
|
|
|
86
96
|
|
|
87
97
|
return (
|
|
88
98
|
<Transition
|
|
89
|
-
{
|
|
99
|
+
nodeRef={nodeRef}
|
|
90
100
|
timeout={timeout}
|
|
91
101
|
in={active}
|
|
92
102
|
onEntering={onEntering}
|
|
@@ -94,6 +104,7 @@ export const AccordionBody = ({
|
|
|
94
104
|
onExit={onExit}
|
|
95
105
|
onExiting={onExiting}
|
|
96
106
|
onExited={onExited}
|
|
107
|
+
{...transitionProps}
|
|
97
108
|
>
|
|
98
109
|
{(status) => {
|
|
99
110
|
const transitionClass = getTransitionClass(status);
|
|
@@ -102,7 +113,7 @@ export const AccordionBody = ({
|
|
|
102
113
|
const style = height == null ? null : { height };
|
|
103
114
|
|
|
104
115
|
return (
|
|
105
|
-
<Tag className={classes} style={{ ...childProps.style, ...style }} {...childProps}>
|
|
116
|
+
<Tag className={classes} ref={nodeRef} style={{ ...childProps.style, ...style }} {...childProps}>
|
|
106
117
|
<div className={listClasses}>{children}</div>
|
|
107
118
|
</Tag>
|
|
108
119
|
);
|
|
@@ -110,4 +121,3 @@ export const AccordionBody = ({
|
|
|
110
121
|
</Transition>
|
|
111
122
|
);
|
|
112
123
|
};
|
|
113
|
-
// }
|
|
@@ -31,7 +31,6 @@ export const AccordionHeader: FC<AccordionHeaderProps> = ({
|
|
|
31
31
|
return (
|
|
32
32
|
<div className='accordion-header' data-testid={testId}>
|
|
33
33
|
<Tag
|
|
34
|
-
data-bs-toggle='collapse'
|
|
35
34
|
aria-expanded={active ? 'true' : 'false'}
|
|
36
35
|
className={toggleClasses}
|
|
37
36
|
onClick={onToggle}
|
|
@@ -1,19 +1,29 @@
|
|
|
1
|
-
import React, { FC } from 'react';
|
|
1
|
+
import React, { FC, useEffect } from 'react';
|
|
2
2
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
3
3
|
// @ts-ignore non ci sono i types
|
|
4
|
-
import BaseAutocomplete from 'accessible-autocomplete/react';
|
|
4
|
+
import BaseAutocomplete from 'accessible-autocomplete/react';
|
|
5
|
+
// Reference to https://www.npmjs.com/package/accessible-autocomplete
|
|
6
|
+
// Implementation example: https://github.com/alphagov/accessible-autocomplete/blob/main/examples/react/index.html
|
|
5
7
|
|
|
6
8
|
export interface AutocompleteAttributes {
|
|
7
9
|
/** Identificativo */
|
|
8
|
-
id
|
|
10
|
+
id: string;
|
|
11
|
+
/** Label */
|
|
12
|
+
label: string;
|
|
13
|
+
/** Valori all'interno della select */
|
|
14
|
+
source: (query: string, syncResults: () => void) => void;
|
|
9
15
|
/** Valori chiave - valore all'interno della select */
|
|
10
|
-
|
|
16
|
+
onConfirm?: (value: string) => void;
|
|
11
17
|
/** Placeholder (default: ``) */
|
|
12
18
|
placeholder?: string;
|
|
13
19
|
/** Valore di default (default: ``) */
|
|
14
20
|
defaultValue?: string;
|
|
15
21
|
/** Modalità display menu (default: `inline`) */
|
|
16
22
|
displayMenu?: string;
|
|
23
|
+
/** Utilizzare per mostrare il successo nella validazione del valore nel campo Input */
|
|
24
|
+
valid?: boolean;
|
|
25
|
+
/** Testo di validazione per l'elemento del moduleo form. */
|
|
26
|
+
validationText?: string;
|
|
17
27
|
/** Funzione ritornante stringa in caso di nessun risultato */
|
|
18
28
|
tNoResults?: () => string;
|
|
19
29
|
/** Funzione ritornante stringa di suggerimento */
|
|
@@ -60,22 +70,63 @@ export const Autocomplete: FC<AutocompleteAttributes> = ({
|
|
|
60
70
|
defaultValue = '',
|
|
61
71
|
displayMenu = 'inline',
|
|
62
72
|
source,
|
|
73
|
+
validationText,
|
|
74
|
+
onConfirm,
|
|
63
75
|
...attributes
|
|
64
76
|
}) => {
|
|
77
|
+
const { id, valid } = attributes;
|
|
78
|
+
const validityCheck = valid === true || valid === false;
|
|
79
|
+
|
|
80
|
+
useEffect(() => {
|
|
81
|
+
const inputElement: HTMLInputElement = document.getElementById(id) as HTMLInputElement;
|
|
82
|
+
const labelElement = inputElement?.parentElement?.parentElement?.getElementsByTagName('label')[0];
|
|
83
|
+
|
|
84
|
+
if (inputElement.value !== '') {
|
|
85
|
+
labelElement?.classList.add('active');
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
inputElement?.addEventListener('focus', () => {
|
|
89
|
+
labelElement?.classList.add('active');
|
|
90
|
+
});
|
|
91
|
+
inputElement?.addEventListener('blur', () => {
|
|
92
|
+
if (inputElement.value === '') {
|
|
93
|
+
labelElement?.classList.remove('active');
|
|
94
|
+
}
|
|
95
|
+
if (onConfirm) {
|
|
96
|
+
onConfirm(inputElement.value);
|
|
97
|
+
}
|
|
98
|
+
});
|
|
99
|
+
}, [id]);
|
|
100
|
+
|
|
65
101
|
return (
|
|
66
|
-
|
|
67
|
-
id
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
102
|
+
<>
|
|
103
|
+
<label htmlFor={attributes.id}>{attributes.label}</label>
|
|
104
|
+
<BaseAutocomplete
|
|
105
|
+
source={source}
|
|
106
|
+
placeholder={placeholder}
|
|
107
|
+
defaultValue={defaultValue}
|
|
108
|
+
displayMenu={displayMenu}
|
|
109
|
+
tAssistiveHint={tAssistiveHint}
|
|
110
|
+
tNoResults={tNoResults}
|
|
111
|
+
tStatusQueryTooShort={tStatusQueryTooShort}
|
|
112
|
+
tStatusNoResults={tStatusNoResults}
|
|
113
|
+
tStatusSelectedOption={tStatusSelectedOption}
|
|
114
|
+
tStatusResults={tStatusResults}
|
|
115
|
+
onConfirm={onConfirm}
|
|
116
|
+
inputClasses={`form-control ${validityCheck && (valid === false ? 'is-invalid' : 'just-validate-success-field')}`}
|
|
117
|
+
showNoOptionsFound={true}
|
|
118
|
+
hintClasses='app-hint'
|
|
119
|
+
autoselect={false}
|
|
120
|
+
showAllValues={false}
|
|
121
|
+
templates={undefined}
|
|
122
|
+
confirmOnBlur={false}
|
|
123
|
+
menuAttributes={null}
|
|
124
|
+
menuClasses={null}
|
|
125
|
+
{...attributes}
|
|
126
|
+
/>
|
|
127
|
+
<div className='form-feedback just-validate-error-label form-text form-feedback just-validate-error-label'>
|
|
128
|
+
{!valid && validationText}
|
|
129
|
+
</div>
|
|
130
|
+
</>
|
|
80
131
|
);
|
|
81
132
|
};
|