@appquality/unguess-design-system 3.1.91-highlight-1 → 3.1.91-highlight-2
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/build/index.js
CHANGED
|
@@ -7519,7 +7519,8 @@ const Observation = core.Node.create({
|
|
|
7519
7519
|
if (node.type.name === "Word") {
|
|
7520
7520
|
// Crea il nodo "active"
|
|
7521
7521
|
const annotationNode = state.schema.nodes.Observation.create({
|
|
7522
|
-
title
|
|
7522
|
+
title,
|
|
7523
|
+
type,
|
|
7523
7524
|
}, node.content);
|
|
7524
7525
|
// Crea il nodo "word" aggiornato con "active" come figlio
|
|
7525
7526
|
const updatedNode = node.copy(model.Fragment.from(annotationNode));
|
|
@@ -7636,7 +7637,7 @@ const Word = core.Node.create({
|
|
|
7636
7637
|
},
|
|
7637
7638
|
});
|
|
7638
7639
|
|
|
7639
|
-
const useEditor = ({ content, currentTime, onSetCurrentTime, }, deps) => {
|
|
7640
|
+
const useEditor = ({ content, observations, currentTime, onSetCurrentTime, }, deps) => {
|
|
7640
7641
|
const ed = react.useEditor({
|
|
7641
7642
|
extensions: [
|
|
7642
7643
|
Document__default["default"],
|
|
@@ -7692,6 +7693,24 @@ const useEditor = ({ content, currentTime, onSetCurrentTime, }, deps) => {
|
|
|
7692
7693
|
return;
|
|
7693
7694
|
ed.commands.updateCurrentActive({ currentWord });
|
|
7694
7695
|
}, [currentTime, content, ed]);
|
|
7696
|
+
React.useEffect(() => {
|
|
7697
|
+
if (!observations)
|
|
7698
|
+
return;
|
|
7699
|
+
if (!ed)
|
|
7700
|
+
return;
|
|
7701
|
+
const selection = ed.state.selection;
|
|
7702
|
+
observations.forEach((observation) => {
|
|
7703
|
+
const startWord = ed.$node("Word", { "data-start": observation.start });
|
|
7704
|
+
const endWord = ed.$node("Word", { "data-end": observation.end });
|
|
7705
|
+
if (!startWord || !endWord)
|
|
7706
|
+
return;
|
|
7707
|
+
ed.chain()
|
|
7708
|
+
.setTextSelection({ from: startWord.pos, to: endWord.pos })
|
|
7709
|
+
.addObservation(observation.type, observation.text)
|
|
7710
|
+
.setTextSelection(selection.from)
|
|
7711
|
+
.run();
|
|
7712
|
+
});
|
|
7713
|
+
}, [observations, ed]);
|
|
7695
7714
|
return ed;
|
|
7696
7715
|
};
|
|
7697
7716
|
|
|
@@ -8,6 +8,10 @@ export declare const variants: readonly [{}, {
|
|
|
8
8
|
readonly disabled: true;
|
|
9
9
|
}];
|
|
10
10
|
export declare const Row: import("styled-components").IStyledComponent<"web", {
|
|
11
|
+
title?: string | undefined;
|
|
12
|
+
content?: string | undefined;
|
|
13
|
+
onClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
14
|
+
children?: import("react").ReactNode;
|
|
11
15
|
onChange?: import("react").FormEventHandler<HTMLDivElement> | undefined;
|
|
12
16
|
defaultChecked?: boolean | undefined;
|
|
13
17
|
defaultValue?: string | number | readonly string[] | undefined;
|
|
@@ -28,12 +32,10 @@ export declare const Row: import("styled-components").IStyledComponent<"web", {
|
|
|
28
32
|
spellCheck?: (boolean | "true" | "false") | undefined;
|
|
29
33
|
style?: import("react").CSSProperties | undefined;
|
|
30
34
|
tabIndex?: number | undefined;
|
|
31
|
-
title?: string | undefined;
|
|
32
35
|
translate?: "yes" | "no" | undefined;
|
|
33
36
|
radioGroup?: string | undefined;
|
|
34
37
|
role?: import("react").AriaRole | undefined;
|
|
35
38
|
about?: string | undefined;
|
|
36
|
-
content?: string | undefined;
|
|
37
39
|
datatype?: string | undefined;
|
|
38
40
|
inlist?: any;
|
|
39
41
|
prefix?: string | undefined;
|
|
@@ -55,7 +57,7 @@ export declare const Row: import("styled-components").IStyledComponent<"web", {
|
|
|
55
57
|
results?: number | undefined;
|
|
56
58
|
security?: string | undefined;
|
|
57
59
|
unselectable?: "on" | "off" | undefined;
|
|
58
|
-
inputMode?: "
|
|
60
|
+
inputMode?: "search" | "none" | "text" | "tel" | "url" | "email" | "numeric" | "decimal" | undefined;
|
|
59
61
|
is?: string | undefined;
|
|
60
62
|
"aria-activedescendant"?: string | undefined;
|
|
61
63
|
"aria-atomic"?: (boolean | "true" | "false") | undefined;
|
|
@@ -79,7 +81,7 @@ export declare const Row: import("styled-components").IStyledComponent<"web", {
|
|
|
79
81
|
"aria-expanded"?: (boolean | "true" | "false") | undefined;
|
|
80
82
|
"aria-flowto"?: string | undefined;
|
|
81
83
|
"aria-grabbed"?: (boolean | "true" | "false") | undefined;
|
|
82
|
-
"aria-haspopup"?: boolean | "true" | "false" | "dialog" | "grid" | "listbox" | "
|
|
84
|
+
"aria-haspopup"?: boolean | "menu" | "true" | "false" | "dialog" | "grid" | "listbox" | "tree" | undefined;
|
|
83
85
|
"aria-hidden"?: (boolean | "true" | "false") | undefined;
|
|
84
86
|
"aria-invalid"?: boolean | "true" | "false" | "grammar" | "spelling" | undefined;
|
|
85
87
|
"aria-keyshortcuts"?: string | undefined;
|
|
@@ -110,7 +112,6 @@ export declare const Row: import("styled-components").IStyledComponent<"web", {
|
|
|
110
112
|
"aria-valuemin"?: number | undefined;
|
|
111
113
|
"aria-valuenow"?: number | undefined;
|
|
112
114
|
"aria-valuetext"?: string | undefined;
|
|
113
|
-
children?: import("react").ReactNode;
|
|
114
115
|
dangerouslySetInnerHTML?: {
|
|
115
116
|
__html: string | TrustedHTML;
|
|
116
117
|
} | undefined;
|
|
@@ -199,7 +200,6 @@ export declare const Row: import("styled-components").IStyledComponent<"web", {
|
|
|
199
200
|
onWaitingCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
|
|
200
201
|
onAuxClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
201
202
|
onAuxClickCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
202
|
-
onClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
203
203
|
onClickCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
204
204
|
onContextMenu?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
205
205
|
onContextMenuCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
@@ -295,6 +295,10 @@ export declare const Row: import("styled-components").IStyledComponent<"web", {
|
|
|
295
295
|
ref?: ((instance: HTMLDivElement | null) => void) | import("react").RefObject<HTMLDivElement> | null | undefined;
|
|
296
296
|
}> & import("react").ForwardRefExoticComponent<import("@zendeskgarden/react-grid").IRowProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
297
297
|
export declare const Col: import("styled-components").IStyledComponent<"web", {
|
|
298
|
+
title?: string | undefined;
|
|
299
|
+
content?: string | undefined;
|
|
300
|
+
onClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
301
|
+
children?: import("react").ReactNode;
|
|
298
302
|
onChange?: import("react").FormEventHandler<HTMLDivElement> | undefined;
|
|
299
303
|
defaultChecked?: boolean | undefined;
|
|
300
304
|
defaultValue?: string | number | readonly string[] | undefined;
|
|
@@ -315,12 +319,10 @@ export declare const Col: import("styled-components").IStyledComponent<"web", {
|
|
|
315
319
|
spellCheck?: (boolean | "true" | "false") | undefined;
|
|
316
320
|
style?: import("react").CSSProperties | undefined;
|
|
317
321
|
tabIndex?: number | undefined;
|
|
318
|
-
title?: string | undefined;
|
|
319
322
|
translate?: "yes" | "no" | undefined;
|
|
320
323
|
radioGroup?: string | undefined;
|
|
321
324
|
role?: import("react").AriaRole | undefined;
|
|
322
325
|
about?: string | undefined;
|
|
323
|
-
content?: string | undefined;
|
|
324
326
|
datatype?: string | undefined;
|
|
325
327
|
inlist?: any;
|
|
326
328
|
prefix?: string | undefined;
|
|
@@ -342,7 +344,7 @@ export declare const Col: import("styled-components").IStyledComponent<"web", {
|
|
|
342
344
|
results?: number | undefined;
|
|
343
345
|
security?: string | undefined;
|
|
344
346
|
unselectable?: "on" | "off" | undefined;
|
|
345
|
-
inputMode?: "
|
|
347
|
+
inputMode?: "search" | "none" | "text" | "tel" | "url" | "email" | "numeric" | "decimal" | undefined;
|
|
346
348
|
is?: string | undefined;
|
|
347
349
|
"aria-activedescendant"?: string | undefined;
|
|
348
350
|
"aria-atomic"?: (boolean | "true" | "false") | undefined;
|
|
@@ -366,7 +368,7 @@ export declare const Col: import("styled-components").IStyledComponent<"web", {
|
|
|
366
368
|
"aria-expanded"?: (boolean | "true" | "false") | undefined;
|
|
367
369
|
"aria-flowto"?: string | undefined;
|
|
368
370
|
"aria-grabbed"?: (boolean | "true" | "false") | undefined;
|
|
369
|
-
"aria-haspopup"?: boolean | "true" | "false" | "dialog" | "grid" | "listbox" | "
|
|
371
|
+
"aria-haspopup"?: boolean | "menu" | "true" | "false" | "dialog" | "grid" | "listbox" | "tree" | undefined;
|
|
370
372
|
"aria-hidden"?: (boolean | "true" | "false") | undefined;
|
|
371
373
|
"aria-invalid"?: boolean | "true" | "false" | "grammar" | "spelling" | undefined;
|
|
372
374
|
"aria-keyshortcuts"?: string | undefined;
|
|
@@ -397,7 +399,6 @@ export declare const Col: import("styled-components").IStyledComponent<"web", {
|
|
|
397
399
|
"aria-valuemin"?: number | undefined;
|
|
398
400
|
"aria-valuenow"?: number | undefined;
|
|
399
401
|
"aria-valuetext"?: string | undefined;
|
|
400
|
-
children?: import("react").ReactNode;
|
|
401
402
|
dangerouslySetInnerHTML?: {
|
|
402
403
|
__html: string | TrustedHTML;
|
|
403
404
|
} | undefined;
|
|
@@ -486,7 +487,6 @@ export declare const Col: import("styled-components").IStyledComponent<"web", {
|
|
|
486
487
|
onWaitingCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
|
|
487
488
|
onAuxClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
488
489
|
onAuxClickCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
489
|
-
onClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
490
490
|
onClickCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
491
491
|
onContextMenu?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
492
492
|
onContextMenuCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
@@ -569,12 +569,12 @@ export declare const Col: import("styled-components").IStyledComponent<"web", {
|
|
|
569
569
|
md?: string | number | boolean | undefined;
|
|
570
570
|
lg?: string | number | boolean | undefined;
|
|
571
571
|
xl?: string | number | boolean | undefined;
|
|
572
|
-
alignSelf?: "center" | "start" | "end" | "baseline" | "stretch" |
|
|
573
|
-
alignSelfXs?: "center" | "start" | "end" | "baseline" | "stretch" |
|
|
574
|
-
alignSelfSm?: "center" | "start" | "end" | "baseline" | "stretch" |
|
|
575
|
-
alignSelfMd?: "center" | "start" | "end" | "baseline" | "stretch" |
|
|
576
|
-
alignSelfLg?: "center" | "start" | "end" | "baseline" | "stretch" |
|
|
577
|
-
alignSelfXl?: "center" | "start" | "end" | "baseline" | "stretch" |
|
|
572
|
+
alignSelf?: "auto" | "center" | "start" | "end" | "baseline" | "stretch" | undefined;
|
|
573
|
+
alignSelfXs?: "auto" | "center" | "start" | "end" | "baseline" | "stretch" | undefined;
|
|
574
|
+
alignSelfSm?: "auto" | "center" | "start" | "end" | "baseline" | "stretch" | undefined;
|
|
575
|
+
alignSelfMd?: "auto" | "center" | "start" | "end" | "baseline" | "stretch" | undefined;
|
|
576
|
+
alignSelfLg?: "auto" | "center" | "start" | "end" | "baseline" | "stretch" | undefined;
|
|
577
|
+
alignSelfXl?: "auto" | "center" | "start" | "end" | "baseline" | "stretch" | undefined;
|
|
578
578
|
textAlign?: "center" | "start" | "end" | "justify" | undefined;
|
|
579
579
|
textAlignXs?: "center" | "start" | "end" | "justify" | undefined;
|
|
580
580
|
textAlignSm?: "center" | "start" | "end" | "justify" | undefined;
|
|
@@ -594,6 +594,10 @@ export declare const Col: import("styled-components").IStyledComponent<"web", {
|
|
|
594
594
|
ref?: ((instance: HTMLDivElement | null) => void) | import("react").RefObject<HTMLDivElement> | null | undefined;
|
|
595
595
|
}> & import("react").ForwardRefExoticComponent<import("@zendeskgarden/react-grid").IColProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
596
596
|
export declare const MD: import("styled-components").IStyledComponent<"web", {
|
|
597
|
+
title?: string | undefined;
|
|
598
|
+
content?: string | undefined;
|
|
599
|
+
onClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
600
|
+
children?: import("react").ReactNode;
|
|
597
601
|
onChange?: import("react").FormEventHandler<HTMLDivElement> | undefined;
|
|
598
602
|
defaultChecked?: boolean | undefined;
|
|
599
603
|
defaultValue?: string | number | readonly string[] | undefined;
|
|
@@ -614,12 +618,10 @@ export declare const MD: import("styled-components").IStyledComponent<"web", {
|
|
|
614
618
|
spellCheck?: (boolean | "true" | "false") | undefined;
|
|
615
619
|
style?: import("react").CSSProperties | undefined;
|
|
616
620
|
tabIndex?: number | undefined;
|
|
617
|
-
title?: string | undefined;
|
|
618
621
|
translate?: "yes" | "no" | undefined;
|
|
619
622
|
radioGroup?: string | undefined;
|
|
620
623
|
role?: import("react").AriaRole | undefined;
|
|
621
624
|
about?: string | undefined;
|
|
622
|
-
content?: string | undefined;
|
|
623
625
|
datatype?: string | undefined;
|
|
624
626
|
inlist?: any;
|
|
625
627
|
prefix?: string | undefined;
|
|
@@ -641,7 +643,7 @@ export declare const MD: import("styled-components").IStyledComponent<"web", {
|
|
|
641
643
|
results?: number | undefined;
|
|
642
644
|
security?: string | undefined;
|
|
643
645
|
unselectable?: "on" | "off" | undefined;
|
|
644
|
-
inputMode?: "
|
|
646
|
+
inputMode?: "search" | "none" | "text" | "tel" | "url" | "email" | "numeric" | "decimal" | undefined;
|
|
645
647
|
is?: string | undefined;
|
|
646
648
|
"aria-activedescendant"?: string | undefined;
|
|
647
649
|
"aria-atomic"?: (boolean | "true" | "false") | undefined;
|
|
@@ -665,7 +667,7 @@ export declare const MD: import("styled-components").IStyledComponent<"web", {
|
|
|
665
667
|
"aria-expanded"?: (boolean | "true" | "false") | undefined;
|
|
666
668
|
"aria-flowto"?: string | undefined;
|
|
667
669
|
"aria-grabbed"?: (boolean | "true" | "false") | undefined;
|
|
668
|
-
"aria-haspopup"?: boolean | "true" | "false" | "dialog" | "grid" | "listbox" | "
|
|
670
|
+
"aria-haspopup"?: boolean | "menu" | "true" | "false" | "dialog" | "grid" | "listbox" | "tree" | undefined;
|
|
669
671
|
"aria-hidden"?: (boolean | "true" | "false") | undefined;
|
|
670
672
|
"aria-invalid"?: boolean | "true" | "false" | "grammar" | "spelling" | undefined;
|
|
671
673
|
"aria-keyshortcuts"?: string | undefined;
|
|
@@ -696,7 +698,6 @@ export declare const MD: import("styled-components").IStyledComponent<"web", {
|
|
|
696
698
|
"aria-valuemin"?: number | undefined;
|
|
697
699
|
"aria-valuenow"?: number | undefined;
|
|
698
700
|
"aria-valuetext"?: string | undefined;
|
|
699
|
-
children?: import("react").ReactNode;
|
|
700
701
|
dangerouslySetInnerHTML?: {
|
|
701
702
|
__html: string | TrustedHTML;
|
|
702
703
|
} | undefined;
|
|
@@ -785,7 +786,6 @@ export declare const MD: import("styled-components").IStyledComponent<"web", {
|
|
|
785
786
|
onWaitingCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
|
|
786
787
|
onAuxClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
787
788
|
onAuxClickCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
788
|
-
onClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
789
789
|
onClickCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
790
790
|
onContextMenu?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
791
791
|
onContextMenuCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const useEditor: ({ content, currentTime, onSetCurrentTime, }: {
|
|
1
|
+
export declare const useEditor: ({ content, observations, currentTime, onSetCurrentTime, }: {
|
|
2
2
|
content?: {
|
|
3
3
|
start: number;
|
|
4
4
|
end: number;
|
|
@@ -9,6 +9,13 @@ export declare const useEditor: ({ content, currentTime, onSetCurrentTime, }: {
|
|
|
9
9
|
word: string;
|
|
10
10
|
}[];
|
|
11
11
|
}[] | undefined;
|
|
12
|
+
observations?: {
|
|
13
|
+
id: number;
|
|
14
|
+
type: string;
|
|
15
|
+
start: number;
|
|
16
|
+
end: number;
|
|
17
|
+
text: string;
|
|
18
|
+
}[] | undefined;
|
|
12
19
|
currentTime?: number | undefined;
|
|
13
20
|
onSetCurrentTime?: ((time: number) => void) | undefined;
|
|
14
21
|
}, deps?: React.DependencyList) => import("@tiptap/react").Editor | null;
|