@topconsultnpm/sdkui-react 6.19.0-dev2.2 → 6.19.0-test.1
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/lib/assets/IconsS4t/add.svg +12 -12
- package/lib/assets/IconsS4t/aggiorna.svg +18 -18
- package/lib/assets/IconsS4t/bookmark.svg +42 -42
- package/lib/assets/IconsS4t/cancella.svg +15 -15
- package/lib/assets/IconsS4t/check-box.svg +19 -19
- package/lib/assets/IconsS4t/down-arrow-signBook.svg +40 -40
- package/lib/assets/IconsS4t/down.svg +28 -28
- package/lib/assets/IconsS4t/edit-file.svg +19 -19
- package/lib/assets/IconsS4t/edita.svg +32 -32
- package/lib/assets/IconsS4t/firma.svg +19 -19
- package/lib/assets/IconsS4t/icona_download.svg +16 -16
- package/lib/assets/IconsS4t/info.svg +51 -51
- package/lib/assets/IconsS4t/left.svg +20 -20
- package/lib/assets/IconsS4t/line.svg +40 -40
- package/lib/assets/IconsS4t/more.svg +19 -19
- package/lib/assets/IconsS4t/plus.svg +23 -23
- package/lib/assets/IconsS4t/printer.svg +49 -49
- package/lib/assets/IconsS4t/radio-on-button.svg +25 -25
- package/lib/assets/IconsS4t/rectangle.svg +41 -41
- package/lib/assets/IconsS4t/redo.svg +19 -19
- package/lib/assets/IconsS4t/right-arrow-signBook-finish.svg +40 -40
- package/lib/assets/IconsS4t/right-arrow-signBook.svg +40 -40
- package/lib/assets/IconsS4t/right.svg +22 -22
- package/lib/assets/IconsS4t/searchbar.svg +21 -21
- package/lib/assets/IconsS4t/text-box.svg +36 -36
- package/lib/assets/IconsS4t/tick.svg +8 -8
- package/lib/assets/IconsS4t/trash-white.svg +10 -10
- package/lib/assets/IconsS4t/undo.svg +19 -19
- package/lib/assets/IconsS4t/up.svg +32 -32
- package/lib/assets/IconsS4t/video-streaming.svg +2 -2
- package/lib/assets/IconsS4t/zoom-in.svg +58 -58
- package/lib/assets/IconsS4t/zoom-out.svg +56 -56
- package/lib/assets/icomoon.svg +96 -96
- package/lib/assets/italy.svg +16 -16
- package/lib/assets/six.svg +3 -3
- package/lib/assets/thumbnails/index.ts +39 -39
- package/lib/assets/topmedia-six.svg +65 -65
- package/lib/assets/topmeida-six-bianco.svg +65 -65
- package/lib/components/base/Styled.js +302 -302
- package/lib/components/base/TMAccordion.js +43 -43
- package/lib/components/base/TMAreaManager.js +23 -23
- package/lib/components/base/TMButton.js +130 -130
- package/lib/components/base/TMClosableList.js +46 -46
- package/lib/components/base/TMConfirm.js +20 -20
- package/lib/components/base/TMContextMenu.js +4 -4
- package/lib/components/base/TMContextMenuOLD.js +25 -25
- package/lib/components/base/TMCounterBar.js +32 -32
- package/lib/components/base/TMCounterContainer.js +30 -30
- package/lib/components/base/TMCustomButton.js +7 -7
- package/lib/components/base/TMDropDownMenu.js +24 -24
- package/lib/components/base/TMFileManagerUtils.js +19 -19
- package/lib/components/base/TMFloatingToolbar.js +34 -34
- package/lib/components/base/TMLayout.js +44 -44
- package/lib/components/base/TMList.js +34 -34
- package/lib/components/base/TMModal.js +31 -31
- package/lib/components/base/TMPanel.js +57 -57
- package/lib/components/base/TMPopUp.js +114 -114
- package/lib/components/base/TMProgressBar.js +20 -20
- package/lib/components/base/TMResizableMenu.js +28 -28
- package/lib/components/base/TMRightSidebar.js +40 -40
- package/lib/components/base/TMSpinner.js +121 -121
- package/lib/components/base/TMTab.js +11 -11
- package/lib/components/base/TMToggleButton.js +36 -36
- package/lib/components/base/TMToolbarCard.js +35 -35
- package/lib/components/base/TMTreeView.js +16 -16
- package/lib/components/base/TMUserAvatar.js +7 -7
- package/lib/components/base/TMWaitPanel.js +22 -22
- package/lib/components/choosers/TMCultureIDPicker.js +35 -35
- package/lib/components/choosers/TMDataListItemPicker.js +54 -54
- package/lib/components/editors/TMCheckBox.js +24 -24
- package/lib/components/editors/TMDropDown.js +43 -43
- package/lib/components/editors/TMEditorStyled.js +71 -71
- package/lib/components/editors/TMHtmlContentDisplay.js +16 -16
- package/lib/components/editors/TMLocalizedTextBox.js +31 -31
- package/lib/components/editors/TMMetadataValues.js +17 -17
- package/lib/components/editors/TMRadioButton.js +39 -39
- package/lib/components/editors/TMSummary.js +39 -39
- package/lib/components/editors/TMTextArea.js +12 -12
- package/lib/components/editors/TMTextBox.js +19 -19
- package/lib/components/features/assistant/ToppyHelpCenter.js +114 -114
- package/lib/components/features/blog/TMBlogCommentForm.js +3 -3
- package/lib/components/features/documents/TMDcmtIcon.js +8 -8
- package/lib/components/features/documents/TMDcmtPreview.js +30 -30
- package/lib/components/features/documents/TMFileUploader.js +21 -21
- package/lib/components/features/search/TMSavedQuerySelector.js +51 -51
- package/lib/components/features/search/TMSearchQueryEditor.js +13 -13
- package/lib/components/features/search/TMSearchQueryPanel.js +30 -30
- package/lib/components/features/search/TMSearchResult.js +3 -3
- package/lib/components/features/search/TMTreeSelector.js +66 -66
- package/lib/components/features/tasks/TMTaskForm.js +31 -31
- package/lib/components/features/wg/TMWGsCopyMoveForm.js +9 -9
- package/lib/components/features/workflow/TMWorkflowPopup.js +41 -41
- package/lib/components/features/workflow/diagram/ConnectionComponent.js +29 -29
- package/lib/components/features/workflow/diagram/ConnectionForm.js +10 -10
- package/lib/components/features/workflow/diagram/DiagramItemComponent.js +57 -57
- package/lib/components/features/workflow/diagram/DiagramItemForm.js +29 -29
- package/lib/components/features/workflow/diagram/DiagramItemSvgContent.js +12 -12
- package/lib/components/features/workflow/diagram/RecipientList.js +38 -38
- package/lib/components/features/workflow/diagram/WFDiagram.js +278 -278
- package/lib/components/features/workflow/diagram/WorkitemRecipientsEditor.js +4 -4
- package/lib/components/forms/Login/Chooser.js +35 -35
- package/lib/components/forms/Login/Menu.js +22 -22
- package/lib/components/forms/Login/SelectBox.js +46 -46
- package/lib/components/forms/Login/TMLoginForm.js +14 -14
- package/lib/components/forms/Login/TextBox.js +57 -57
- package/lib/components/grids/TMBlogsPostUtils.js +5 -5
- package/lib/components/grids/TMRecentsManager.js +50 -50
- package/lib/components/grids/TMValidationItemsList.js +48 -48
- package/lib/components/layout/panelManager/TMPanelManagerContainer.js +12 -12
- package/lib/components/layout/panelManager/TMPanelManagerToolbar.js +34 -34
- package/lib/components/query/TMQueryEditor.js +17 -17
- package/lib/components/query/TMQuerySummary.js +12 -12
- package/lib/components/settings/SettingsAppearance.js +0 -8
- package/lib/components/sidebar/TMCommandsPanel.js +10 -10
- package/lib/components/sidebar/TMHeader.js +307 -307
- package/lib/components/sidebar/TMSidebar.js +24 -24
- package/lib/components/sidebar/TMSidebarItem.js +21 -21
- package/lib/components/wizard/TMStepIndicator.js +102 -102
- package/lib/components/wizard/TMWizard.js +29 -29
- package/lib/helper/SDKUI_Globals.d.ts +0 -2
- package/lib/helper/SDKUI_Globals.js +1 -9
- package/lib/helper/TMIcons.js +1 -1
- package/lib/helper/TMToppyMessage.js +30 -30
- package/lib/helper/TMUtils.js +37 -37
- package/package.json +54 -54
|
@@ -14,49 +14,49 @@ const TMAccordion = ({ title, titleSize = 'Medium', children, defaultOpen = true
|
|
|
14
14
|
};
|
|
15
15
|
export default TMAccordion;
|
|
16
16
|
//#region Styled Components
|
|
17
|
-
const StyledAccordionContainer = styled.div `
|
|
18
|
-
margin-bottom: 10px;
|
|
19
|
-
overflow: hidden;
|
|
17
|
+
const StyledAccordionContainer = styled.div `
|
|
18
|
+
margin-bottom: 10px;
|
|
19
|
+
overflow: hidden;
|
|
20
20
|
`;
|
|
21
|
-
const StyledGroupTemplate = styled.div `
|
|
22
|
-
cursor: pointer;
|
|
23
|
-
background: none !important;
|
|
24
|
-
border: none !important;
|
|
25
|
-
box-shadow: none !important;
|
|
26
|
-
padding: 10px;
|
|
27
|
-
display: flex;
|
|
28
|
-
flex-direction: row;
|
|
29
|
-
gap: 5px;
|
|
30
|
-
align-items: center;
|
|
31
|
-
font-size: 1rem;
|
|
32
|
-
font-weight: 600;
|
|
33
|
-
color: ${() => TMColors.primaryColor};
|
|
34
|
-
position: relative;
|
|
35
|
-
|
|
36
|
-
.tm-accordion-title, .tm-accordion-title.small {
|
|
37
|
-
font-weight: 600;
|
|
38
|
-
margin: 0;
|
|
39
|
-
}
|
|
40
|
-
.tm-accordion-title.small {
|
|
41
|
-
font-size: 1rem;
|
|
42
|
-
}
|
|
43
|
-
.tm-accordion-title {
|
|
44
|
-
font-size: 1.25rem;
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
&::after {
|
|
48
|
-
content: '';
|
|
49
|
-
display: block;
|
|
50
|
-
width: 90%;
|
|
51
|
-
margin: 0 auto;
|
|
52
|
-
border-bottom: 1px solid #00A99D;
|
|
53
|
-
margin-top: 8px;
|
|
54
|
-
position: absolute;
|
|
55
|
-
left: 5%;
|
|
56
|
-
bottom: 0;
|
|
57
|
-
}
|
|
21
|
+
const StyledGroupTemplate = styled.div `
|
|
22
|
+
cursor: pointer;
|
|
23
|
+
background: none !important;
|
|
24
|
+
border: none !important;
|
|
25
|
+
box-shadow: none !important;
|
|
26
|
+
padding: 10px;
|
|
27
|
+
display: flex;
|
|
28
|
+
flex-direction: row;
|
|
29
|
+
gap: 5px;
|
|
30
|
+
align-items: center;
|
|
31
|
+
font-size: 1rem;
|
|
32
|
+
font-weight: 600;
|
|
33
|
+
color: ${() => TMColors.primaryColor};
|
|
34
|
+
position: relative;
|
|
35
|
+
|
|
36
|
+
.tm-accordion-title, .tm-accordion-title.small {
|
|
37
|
+
font-weight: 600;
|
|
38
|
+
margin: 0;
|
|
39
|
+
}
|
|
40
|
+
.tm-accordion-title.small {
|
|
41
|
+
font-size: 1rem;
|
|
42
|
+
}
|
|
43
|
+
.tm-accordion-title {
|
|
44
|
+
font-size: 1.25rem;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
&::after {
|
|
48
|
+
content: '';
|
|
49
|
+
display: block;
|
|
50
|
+
width: 90%;
|
|
51
|
+
margin: 0 auto;
|
|
52
|
+
border-bottom: 1px solid #00A99D;
|
|
53
|
+
margin-top: 8px;
|
|
54
|
+
position: absolute;
|
|
55
|
+
left: 5%;
|
|
56
|
+
bottom: 0;
|
|
57
|
+
}
|
|
58
58
|
`;
|
|
59
|
-
const StyledAccordionContent = styled.div `
|
|
60
|
-
padding: 10px;
|
|
61
|
-
background-color: #fff; /* White background for the content area */
|
|
59
|
+
const StyledAccordionContent = styled.div `
|
|
60
|
+
padding: 10px;
|
|
61
|
+
background-color: #fff; /* White background for the content area */
|
|
62
62
|
`;
|
|
@@ -27,29 +27,29 @@ export class TMFileSystemItem {
|
|
|
27
27
|
let abortController = new AbortController();
|
|
28
28
|
const svgString = encodeURIComponent(renderToStaticMarkup(_jsx(IconFolderForCSS, { fill: "#9fc6e7" })));
|
|
29
29
|
const svgDataUrl = `data:image/svg+xml,${svgString}`;
|
|
30
|
-
const StyledFileManagerWrapper = styled.div `
|
|
31
|
-
.dx-filemanager .dx-treeview-item .dx-icon-folder {
|
|
32
|
-
display: none !important;
|
|
33
|
-
}
|
|
34
|
-
.dx-filemanager .dx-treeview-item .dx-treeview-item-content {
|
|
35
|
-
position: relative !important;
|
|
36
|
-
padding-left: 26px !important;
|
|
37
|
-
min-height: 22px !important;
|
|
38
|
-
}
|
|
39
|
-
.dx-filemanager .dx-treeview-item .dx-treeview-item-content::before {
|
|
40
|
-
content: '';
|
|
41
|
-
position: absolute;
|
|
42
|
-
left: 0;
|
|
43
|
-
top: 60%;
|
|
44
|
-
width: 20px;
|
|
45
|
-
height: 20px;
|
|
46
|
-
transform: translateY(-50%);
|
|
47
|
-
background-image: url("${svgDataUrl}");
|
|
48
|
-
background-size: contain;
|
|
49
|
-
background-repeat: no-repeat;
|
|
50
|
-
display: inline-block;
|
|
51
|
-
z-index: 1;
|
|
52
|
-
}
|
|
30
|
+
const StyledFileManagerWrapper = styled.div `
|
|
31
|
+
.dx-filemanager .dx-treeview-item .dx-icon-folder {
|
|
32
|
+
display: none !important;
|
|
33
|
+
}
|
|
34
|
+
.dx-filemanager .dx-treeview-item .dx-treeview-item-content {
|
|
35
|
+
position: relative !important;
|
|
36
|
+
padding-left: 26px !important;
|
|
37
|
+
min-height: 22px !important;
|
|
38
|
+
}
|
|
39
|
+
.dx-filemanager .dx-treeview-item .dx-treeview-item-content::before {
|
|
40
|
+
content: '';
|
|
41
|
+
position: absolute;
|
|
42
|
+
left: 0;
|
|
43
|
+
top: 60%;
|
|
44
|
+
width: 20px;
|
|
45
|
+
height: 20px;
|
|
46
|
+
transform: translateY(-50%);
|
|
47
|
+
background-image: url("${svgDataUrl}");
|
|
48
|
+
background-size: contain;
|
|
49
|
+
background-repeat: no-repeat;
|
|
50
|
+
display: inline-block;
|
|
51
|
+
z-index: 1;
|
|
52
|
+
}
|
|
53
53
|
`;
|
|
54
54
|
const TMAreaManager = (props = { selectionMode: 'multiple', isPathChooser: false }) => {
|
|
55
55
|
// State to store the instance of CustomFileSystemProvider. It is initialized once and used for managing file system operations.
|
|
@@ -4,145 +4,145 @@ import styled from 'styled-components';
|
|
|
4
4
|
import { getColor } from '../../helper';
|
|
5
5
|
import { FontSize, TMColors } from '../../utils/theme';
|
|
6
6
|
import TMTooltip from './TMTooltip';
|
|
7
|
-
const StyledNormalButton = styled.button.withConfig({ shouldForwardProp: prop => !['text'].includes(prop) }) `
|
|
8
|
-
font-size: ${props => props.fontSize};
|
|
9
|
-
width: ${props => props.width && props.width};
|
|
10
|
-
height: ${props => props.height && props.height};
|
|
11
|
-
min-width: 60px;
|
|
12
|
-
min-height: 25px;
|
|
13
|
-
padding: 3px 10px;
|
|
14
|
-
border: none;
|
|
15
|
-
cursor: ${props => !props.disabled && 'pointer'};
|
|
16
|
-
border-radius: 3px;
|
|
17
|
-
border: 1px solid;
|
|
18
|
-
border-color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(225, 225, 225)'};
|
|
19
|
-
background-color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? 'white' : getColor(props.color) : 'rgb(225, 225, 225)'};
|
|
20
|
-
color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(160, 160, 160)'};
|
|
21
|
-
&:hover {
|
|
22
|
-
border-color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(225, 225, 225)'};
|
|
23
|
-
background-color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? 'white' : getColor(props.color.split('Outline')[0]) : 'rgb(225, 225, 225)'};
|
|
24
|
-
color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(160, 160, 160)'};
|
|
25
|
-
}
|
|
7
|
+
const StyledNormalButton = styled.button.withConfig({ shouldForwardProp: prop => !['text'].includes(prop) }) `
|
|
8
|
+
font-size: ${props => props.fontSize};
|
|
9
|
+
width: ${props => props.width && props.width};
|
|
10
|
+
height: ${props => props.height && props.height};
|
|
11
|
+
min-width: 60px;
|
|
12
|
+
min-height: 25px;
|
|
13
|
+
padding: 3px 10px;
|
|
14
|
+
border: none;
|
|
15
|
+
cursor: ${props => !props.disabled && 'pointer'};
|
|
16
|
+
border-radius: 3px;
|
|
17
|
+
border: 1px solid;
|
|
18
|
+
border-color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(225, 225, 225)'};
|
|
19
|
+
background-color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? 'white' : getColor(props.color) : 'rgb(225, 225, 225)'};
|
|
20
|
+
color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(160, 160, 160)'};
|
|
21
|
+
&:hover {
|
|
22
|
+
border-color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(225, 225, 225)'};
|
|
23
|
+
background-color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? 'white' : getColor(props.color.split('Outline')[0]) : 'rgb(225, 225, 225)'};
|
|
24
|
+
color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(160, 160, 160)'};
|
|
25
|
+
}
|
|
26
26
|
`;
|
|
27
|
-
const StyledToolbarButton = styled.button.withConfig({ shouldForwardProp: prop => !['text'].includes(prop) }) `
|
|
28
|
-
font-size: ${props => props.fontSize ? props.fontSize : '18px'};
|
|
29
|
-
width: 30px;
|
|
30
|
-
height: 30px;
|
|
31
|
-
padding: 5px;
|
|
32
|
-
border-radius: 50px;
|
|
33
|
-
display: flex;
|
|
34
|
-
flex: 1;
|
|
35
|
-
align-items: center;
|
|
36
|
-
justify-content: center;
|
|
37
|
-
border: none;
|
|
38
|
-
cursor: ${props => !props.disabled && 'pointer'};
|
|
39
|
-
border: 1px solid;
|
|
40
|
-
border-color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'none' : 'rgb(225, 225, 225)'};
|
|
41
|
-
background-color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? 'white' : getColor(props.color) : 'rgb(225, 225, 225)'};
|
|
42
|
-
color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(160, 160, 160)'};
|
|
43
|
-
&:hover {
|
|
44
|
-
border-color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(225, 225, 225)'};
|
|
45
|
-
background-color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? 'white' : getColor(props.color.split('Outline')[0]) : 'rgb(225, 225, 225)'};
|
|
46
|
-
color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(160, 160, 160)'};
|
|
47
|
-
}
|
|
27
|
+
const StyledToolbarButton = styled.button.withConfig({ shouldForwardProp: prop => !['text'].includes(prop) }) `
|
|
28
|
+
font-size: ${props => props.fontSize ? props.fontSize : '18px'};
|
|
29
|
+
width: 30px;
|
|
30
|
+
height: 30px;
|
|
31
|
+
padding: 5px;
|
|
32
|
+
border-radius: 50px;
|
|
33
|
+
display: flex;
|
|
34
|
+
flex: 1;
|
|
35
|
+
align-items: center;
|
|
36
|
+
justify-content: center;
|
|
37
|
+
border: none;
|
|
38
|
+
cursor: ${props => !props.disabled && 'pointer'};
|
|
39
|
+
border: 1px solid;
|
|
40
|
+
border-color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'none' : 'rgb(225, 225, 225)'};
|
|
41
|
+
background-color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? 'white' : getColor(props.color) : 'rgb(225, 225, 225)'};
|
|
42
|
+
color: ${props => !props.disabled ? props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(160, 160, 160)'};
|
|
43
|
+
&:hover {
|
|
44
|
+
border-color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(225, 225, 225)'};
|
|
45
|
+
background-color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? 'white' : getColor(props.color.split('Outline')[0]) : 'rgb(225, 225, 225)'};
|
|
46
|
+
color: ${props => !props.disabled ? !props.color?.toLowerCase().includes('outline') ? getColor(props.color.split('Outline')[0]) : 'white' : 'rgb(160, 160, 160)'};
|
|
47
|
+
}
|
|
48
48
|
`;
|
|
49
|
-
const StyledIconButton = styled.button.withConfig({ shouldForwardProp: prop => !['text'].includes(prop) }) `
|
|
50
|
-
font-size: ${props => props.fontSize};
|
|
51
|
-
min-width: 10px;
|
|
52
|
-
min-height: 10px;
|
|
53
|
-
padding: ${props => props.padding ?? '0px'};
|
|
54
|
-
display: flex;
|
|
55
|
-
border: none;
|
|
56
|
-
flex: 1;
|
|
57
|
-
align-items: center;
|
|
58
|
-
justify-content: center;
|
|
59
|
-
cursor: ${props => !props.disabled && 'pointer'};
|
|
60
|
-
opacity: ${props => !props.disabled ? 1 : 0.4};
|
|
61
|
-
background-color: transparent;
|
|
62
|
-
color: ${props => !props.disabled ? getColor(props.color) : 'rgb(180, 180, 180)'};
|
|
63
|
-
user-select: none;
|
|
49
|
+
const StyledIconButton = styled.button.withConfig({ shouldForwardProp: prop => !['text'].includes(prop) }) `
|
|
50
|
+
font-size: ${props => props.fontSize};
|
|
51
|
+
min-width: 10px;
|
|
52
|
+
min-height: 10px;
|
|
53
|
+
padding: ${props => props.padding ?? '0px'};
|
|
54
|
+
display: flex;
|
|
55
|
+
border: none;
|
|
56
|
+
flex: 1;
|
|
57
|
+
align-items: center;
|
|
58
|
+
justify-content: center;
|
|
59
|
+
cursor: ${props => !props.disabled && 'pointer'};
|
|
60
|
+
opacity: ${props => !props.disabled ? 1 : 0.4};
|
|
61
|
+
background-color: transparent;
|
|
62
|
+
color: ${props => !props.disabled ? getColor(props.color) : 'rgb(180, 180, 180)'};
|
|
63
|
+
user-select: none;
|
|
64
64
|
`;
|
|
65
|
-
const StyledTextButton = styled.button.withConfig({ shouldForwardProp: prop => !['text'].includes(prop) }) `
|
|
66
|
-
font-size: ${props => props.fontSize};
|
|
67
|
-
width: ${props => props.width && props.width};
|
|
68
|
-
height: ${props => props.height && props.height};
|
|
69
|
-
min-width: 60px;
|
|
70
|
-
min-height: 30px;
|
|
71
|
-
padding: 3px;
|
|
72
|
-
display: flex;
|
|
73
|
-
border: none;
|
|
74
|
-
flex: 1;
|
|
75
|
-
align-items: center;
|
|
76
|
-
justify-content: center;
|
|
77
|
-
cursor: ${props => !props.disabled && 'pointer'};
|
|
78
|
-
border-radius: 2px;
|
|
79
|
-
background-color: transparent;
|
|
80
|
-
color: ${props => !props.disabled ? getColor(props.color) : 'rgb(231, 231, 231)'};
|
|
81
|
-
user-select: none;
|
|
82
|
-
transition: ease 200ms;
|
|
83
|
-
&:hover {
|
|
84
|
-
background-color: rgb(241, 241, 241);
|
|
85
|
-
}
|
|
65
|
+
const StyledTextButton = styled.button.withConfig({ shouldForwardProp: prop => !['text'].includes(prop) }) `
|
|
66
|
+
font-size: ${props => props.fontSize};
|
|
67
|
+
width: ${props => props.width && props.width};
|
|
68
|
+
height: ${props => props.height && props.height};
|
|
69
|
+
min-width: 60px;
|
|
70
|
+
min-height: 30px;
|
|
71
|
+
padding: 3px;
|
|
72
|
+
display: flex;
|
|
73
|
+
border: none;
|
|
74
|
+
flex: 1;
|
|
75
|
+
align-items: center;
|
|
76
|
+
justify-content: center;
|
|
77
|
+
cursor: ${props => !props.disabled && 'pointer'};
|
|
78
|
+
border-radius: 2px;
|
|
79
|
+
background-color: transparent;
|
|
80
|
+
color: ${props => !props.disabled ? getColor(props.color) : 'rgb(231, 231, 231)'};
|
|
81
|
+
user-select: none;
|
|
82
|
+
transition: ease 200ms;
|
|
83
|
+
&:hover {
|
|
84
|
+
background-color: rgb(241, 241, 241);
|
|
85
|
+
}
|
|
86
86
|
`;
|
|
87
|
-
const StyledButtonTooltipHeader = styled.div `
|
|
88
|
-
display: flex;
|
|
89
|
-
flex-direction: row;
|
|
90
|
-
justify-content: flex-start;
|
|
91
|
-
align-items: center;
|
|
92
|
-
background-color: white;
|
|
93
|
-
width: 100%;
|
|
94
|
-
height: 28px;
|
|
95
|
-
padding: 0 5px;
|
|
96
|
-
border-bottom: ${props => props.$description ? '1px solid rgb(210, 210, 210)' : 'none'};
|
|
97
|
-
margin-bottom: ${props => props.$description ? '5px' : '0px'};
|
|
87
|
+
const StyledButtonTooltipHeader = styled.div `
|
|
88
|
+
display: flex;
|
|
89
|
+
flex-direction: row;
|
|
90
|
+
justify-content: flex-start;
|
|
91
|
+
align-items: center;
|
|
92
|
+
background-color: white;
|
|
93
|
+
width: 100%;
|
|
94
|
+
height: 28px;
|
|
95
|
+
padding: 0 5px;
|
|
96
|
+
border-bottom: ${props => props.$description ? '1px solid rgb(210, 210, 210)' : 'none'};
|
|
97
|
+
margin-bottom: ${props => props.$description ? '5px' : '0px'};
|
|
98
98
|
`;
|
|
99
|
-
const StyledButtonTooltipIcon = styled.div `
|
|
100
|
-
margin-right: 5px;
|
|
101
|
-
color: ${props => props.$color ? props.$color : "primary"};
|
|
102
|
-
font-size: '20px';
|
|
99
|
+
const StyledButtonTooltipIcon = styled.div `
|
|
100
|
+
margin-right: 5px;
|
|
101
|
+
color: ${props => props.$color ? props.$color : "primary"};
|
|
102
|
+
font-size: '20px';
|
|
103
103
|
`;
|
|
104
|
-
const StyledButtonTooltipItem = styled.div `
|
|
105
|
-
margin-right: 5px;
|
|
106
|
-
color: ${props => props.$color ? props.$color : "primary"};
|
|
107
|
-
font-size: ${props => props.fontSize || FontSize.defaultFontSize};
|
|
104
|
+
const StyledButtonTooltipItem = styled.div `
|
|
105
|
+
margin-right: 5px;
|
|
106
|
+
color: ${props => props.$color ? props.$color : "primary"};
|
|
107
|
+
font-size: ${props => props.fontSize || FontSize.defaultFontSize};
|
|
108
108
|
`;
|
|
109
|
-
const StyledAdvancedButton = styled.button `
|
|
110
|
-
display: flex;
|
|
111
|
-
align-items: center;
|
|
112
|
-
justify-content: flex-end;
|
|
113
|
-
width: ${props => props.$width};
|
|
114
|
-
height: ${props => props.$height};
|
|
115
|
-
font-weight: 600;
|
|
116
|
-
cursor: ${props => !props.$isDisabled ? 'pointer' : 'default'};
|
|
117
|
-
border-radius: 10px;
|
|
118
|
-
overflow: hidden;
|
|
119
|
-
color: ${({ $isPrimaryOutline }) => $isPrimaryOutline ? TMColors.primaryColor : 'white'};
|
|
120
|
-
user-select: none;
|
|
121
|
-
border: ${({ $isPrimaryOutline }) => $isPrimaryOutline ? `1px solid ${TMColors.primaryColor}` : 'none'};
|
|
122
|
-
background: ${({ $isPrimaryOutline }) => $isPrimaryOutline ? 'white' : 'unset'};
|
|
109
|
+
const StyledAdvancedButton = styled.button `
|
|
110
|
+
display: flex;
|
|
111
|
+
align-items: center;
|
|
112
|
+
justify-content: flex-end;
|
|
113
|
+
width: ${props => props.$width};
|
|
114
|
+
height: ${props => props.$height};
|
|
115
|
+
font-weight: 600;
|
|
116
|
+
cursor: ${props => !props.$isDisabled ? 'pointer' : 'default'};
|
|
117
|
+
border-radius: 10px;
|
|
118
|
+
overflow: hidden;
|
|
119
|
+
color: ${({ $isPrimaryOutline }) => $isPrimaryOutline ? TMColors.primaryColor : 'white'};
|
|
120
|
+
user-select: none;
|
|
121
|
+
border: ${({ $isPrimaryOutline }) => $isPrimaryOutline ? `1px solid ${TMColors.primaryColor}` : 'none'};
|
|
122
|
+
background: ${({ $isPrimaryOutline }) => $isPrimaryOutline ? 'white' : 'unset'};
|
|
123
123
|
`;
|
|
124
|
-
const StyledAdvancedButtonIcon = styled.div `
|
|
125
|
-
display: flex;
|
|
126
|
-
align-items: center;
|
|
127
|
-
justify-content: center;
|
|
128
|
-
width: ${props => props.$isVisible ? '25px' : '0px'};
|
|
129
|
-
|
|
130
|
-
transition: width ease-in-out 100ms;
|
|
131
|
-
height: 100%;
|
|
132
|
-
background-color: ${props => props.$isDisabled ? '#b4b4b4' : props.$color ? `${props.$color}90` : props.$type === 'success' ? `${TMColors.success}90` : props.$type === 'error' ? `${TMColors.error}90` : props.$type === 'tertiary' ? `${TMColors.tertiary}90` : `${TMColors.primary}90`};
|
|
133
|
-
border-top-left-radius: 10px;
|
|
134
|
-
border-bottom-left-radius: 10px;
|
|
124
|
+
const StyledAdvancedButtonIcon = styled.div `
|
|
125
|
+
display: flex;
|
|
126
|
+
align-items: center;
|
|
127
|
+
justify-content: center;
|
|
128
|
+
width: ${props => props.$isVisible ? '25px' : '0px'};
|
|
129
|
+
|
|
130
|
+
transition: width ease-in-out 100ms;
|
|
131
|
+
height: 100%;
|
|
132
|
+
background-color: ${props => props.$isDisabled ? '#b4b4b4' : props.$color ? `${props.$color}90` : props.$type === 'success' ? `${TMColors.success}90` : props.$type === 'error' ? `${TMColors.error}90` : props.$type === 'tertiary' ? `${TMColors.tertiary}90` : `${TMColors.primary}90`};
|
|
133
|
+
border-top-left-radius: 10px;
|
|
134
|
+
border-bottom-left-radius: 10px;
|
|
135
135
|
`;
|
|
136
|
-
const StyledAdvancedButtonText = styled.div `
|
|
137
|
-
display: flex;
|
|
138
|
-
align-items: center;
|
|
139
|
-
justify-content: center;
|
|
140
|
-
width: 100%;
|
|
141
|
-
height: 100%;
|
|
142
|
-
background-color: ${props => props.$isDisabled ? '#d1d1d1' : props.$color ? props.$color : props.$type === 'success' ? `${TMColors.success}` : props.$type === 'error' ? `${TMColors.error}` : props.$type === 'tertiary' ? `${TMColors.tertiary}` : `${TMColors.primary}`};
|
|
143
|
-
border-top-right-radius: 10px;
|
|
144
|
-
border-bottom-right-radius: 10px;
|
|
145
|
-
padding: 5px;
|
|
136
|
+
const StyledAdvancedButtonText = styled.div `
|
|
137
|
+
display: flex;
|
|
138
|
+
align-items: center;
|
|
139
|
+
justify-content: center;
|
|
140
|
+
width: 100%;
|
|
141
|
+
height: 100%;
|
|
142
|
+
background-color: ${props => props.$isDisabled ? '#d1d1d1' : props.$color ? props.$color : props.$type === 'success' ? `${TMColors.success}` : props.$type === 'error' ? `${TMColors.error}` : props.$type === 'tertiary' ? `${TMColors.tertiary}` : `${TMColors.primary}`};
|
|
143
|
+
border-top-right-radius: 10px;
|
|
144
|
+
border-bottom-right-radius: 10px;
|
|
145
|
+
padding: 5px;
|
|
146
146
|
`;
|
|
147
147
|
const TMButton = forwardRef((props, ref) => {
|
|
148
148
|
const { width, height, keyGesture, btnStyle = 'normal', advancedColor, advancedType = 'primary', color = 'primary', fontSize = FontSize.defaultFontSize, disabled = false, showTooltip = true, caption, icon, description, padding, elementStyle, onClick = () => { } } = props;
|
|
@@ -4,58 +4,58 @@ import styled from 'styled-components';
|
|
|
4
4
|
import { Colors, FontSize } from '../../utils/theme';
|
|
5
5
|
import { IconDown, IconRight, SDKUI_Localizator } from '../../helper';
|
|
6
6
|
import { DeviceType, useDeviceType } from './TMDeviceProvider';
|
|
7
|
-
const StyledClosableContainer = styled.div `
|
|
8
|
-
background-color: rgb(248,248,248);
|
|
9
|
-
border-radius: 5px;
|
|
10
|
-
padding: ${props => props.$padding};
|
|
11
|
-
display: flex;
|
|
12
|
-
flex-direction: ${props => !props.$isMobile ? 'row' : 'column'};
|
|
13
|
-
align-items: flex-start;
|
|
14
|
-
justify-content: space-between;
|
|
15
|
-
width: 100%;
|
|
16
|
-
margin-bottom: 5px;
|
|
7
|
+
const StyledClosableContainer = styled.div `
|
|
8
|
+
background-color: rgb(248,248,248);
|
|
9
|
+
border-radius: 5px;
|
|
10
|
+
padding: ${props => props.$padding};
|
|
11
|
+
display: flex;
|
|
12
|
+
flex-direction: ${props => !props.$isMobile ? 'row' : 'column'};
|
|
13
|
+
align-items: flex-start;
|
|
14
|
+
justify-content: space-between;
|
|
15
|
+
width: 100%;
|
|
16
|
+
margin-bottom: 5px;
|
|
17
17
|
`;
|
|
18
|
-
const StyledClosableContext = styled.div `
|
|
19
|
-
display: flex;
|
|
20
|
-
flex-direction: row;
|
|
21
|
-
align-items: flex-start;
|
|
22
|
-
justify-content: flex-start;
|
|
18
|
+
const StyledClosableContext = styled.div `
|
|
19
|
+
display: flex;
|
|
20
|
+
flex-direction: row;
|
|
21
|
+
align-items: flex-start;
|
|
22
|
+
justify-content: flex-start;
|
|
23
23
|
`;
|
|
24
|
-
const StyledClosableLabel = styled.div `
|
|
25
|
-
/* color: black; */
|
|
26
|
-
font-size: ${FontSize.defaultFontSize};
|
|
27
|
-
width: ${props => props.$inline ? '100%' : !props.$isMobile && '180px'};
|
|
28
|
-
padding: 1px;
|
|
24
|
+
const StyledClosableLabel = styled.div `
|
|
25
|
+
/* color: black; */
|
|
26
|
+
font-size: ${FontSize.defaultFontSize};
|
|
27
|
+
width: ${props => props.$inline ? '100%' : !props.$isMobile && '180px'};
|
|
28
|
+
padding: 1px;
|
|
29
29
|
`;
|
|
30
|
-
const StyledClosableItems = styled.div `
|
|
31
|
-
display: flex;
|
|
32
|
-
flex-direction: column;
|
|
33
|
-
align-items: flex-start;
|
|
34
|
-
justify-content: flex-start;
|
|
35
|
-
width: ${props => props.$inline ? '100%' : !props.$isMobile && 'calc(100% - 180px)'};
|
|
30
|
+
const StyledClosableItems = styled.div `
|
|
31
|
+
display: flex;
|
|
32
|
+
flex-direction: column;
|
|
33
|
+
align-items: flex-start;
|
|
34
|
+
justify-content: flex-start;
|
|
35
|
+
width: ${props => props.$inline ? '100%' : !props.$isMobile && 'calc(100% - 180px)'};
|
|
36
36
|
`;
|
|
37
|
-
const StyledClosableItem = styled.div `
|
|
38
|
-
/* font-weight: bold; */
|
|
39
|
-
font-size: ${FontSize.defaultFontSize};
|
|
40
|
-
padding: 2px;
|
|
37
|
+
const StyledClosableItem = styled.div `
|
|
38
|
+
/* font-weight: bold; */
|
|
39
|
+
font-size: ${FontSize.defaultFontSize};
|
|
40
|
+
padding: 2px;
|
|
41
41
|
`;
|
|
42
|
-
const StyledClosabelIcon = styled.div `
|
|
43
|
-
/* color: ${Colors.primary}; */
|
|
44
|
-
font-size: ${FontSize.defaultFontSize};
|
|
45
|
-
cursor: pointer;
|
|
46
|
-
display: flex;
|
|
47
|
-
flex-direction: row;
|
|
48
|
-
align-items: center;
|
|
49
|
-
justify-content: flex-start;
|
|
50
|
-
padding: 2px;
|
|
51
|
-
user-select: none;
|
|
42
|
+
const StyledClosabelIcon = styled.div `
|
|
43
|
+
/* color: ${Colors.primary}; */
|
|
44
|
+
font-size: ${FontSize.defaultFontSize};
|
|
45
|
+
cursor: pointer;
|
|
46
|
+
display: flex;
|
|
47
|
+
flex-direction: row;
|
|
48
|
+
align-items: center;
|
|
49
|
+
justify-content: flex-start;
|
|
50
|
+
padding: 2px;
|
|
51
|
+
user-select: none;
|
|
52
52
|
`;
|
|
53
|
-
const StyledClosableItemsCount = styled.div `
|
|
54
|
-
/* color: ${Colors.primary}; */
|
|
55
|
-
font-size: ${FontSize.defaultFontSize};
|
|
56
|
-
cursor: pointer;
|
|
57
|
-
margin-right: 5px;
|
|
58
|
-
user-select: none;
|
|
53
|
+
const StyledClosableItemsCount = styled.div `
|
|
54
|
+
/* color: ${Colors.primary}; */
|
|
55
|
+
font-size: ${FontSize.defaultFontSize};
|
|
56
|
+
cursor: pointer;
|
|
57
|
+
margin-right: 5px;
|
|
58
|
+
user-select: none;
|
|
59
59
|
`;
|
|
60
60
|
const TMClosableList = ({ dataSource, visibility = false, label, inline = false, hasPadding = true }) => {
|
|
61
61
|
const [status, setStatus] = useState(visibility);
|
|
@@ -8,28 +8,28 @@ import TMButton from './TMButton';
|
|
|
8
8
|
import Toppy from '../../assets/Toppy-generico.png';
|
|
9
9
|
import { TMColors } from '../../utils/theme';
|
|
10
10
|
// *** Stili per la modale (immutati) ***
|
|
11
|
-
const StyledModalBodyWrapper = styled.div `
|
|
12
|
-
display: flex;
|
|
13
|
-
flex-direction: column;
|
|
14
|
-
height: 100%;
|
|
11
|
+
const StyledModalBodyWrapper = styled.div `
|
|
12
|
+
display: flex;
|
|
13
|
+
flex-direction: column;
|
|
14
|
+
height: 100%;
|
|
15
15
|
`;
|
|
16
|
-
const StyledModalFooter = styled.div `
|
|
17
|
-
padding: 12px;
|
|
18
|
-
height: auto;
|
|
19
|
-
display: flex;
|
|
20
|
-
justify-content: flex-end;
|
|
21
|
-
flex-direction: row;
|
|
22
|
-
gap: 10px;
|
|
16
|
+
const StyledModalFooter = styled.div `
|
|
17
|
+
padding: 12px;
|
|
18
|
+
height: auto;
|
|
19
|
+
display: flex;
|
|
20
|
+
justify-content: flex-end;
|
|
21
|
+
flex-direction: row;
|
|
22
|
+
gap: 10px;
|
|
23
23
|
`;
|
|
24
|
-
const StyledModalContentContainer = styled.div `
|
|
25
|
-
width: 100%;
|
|
26
|
-
padding: 10px;
|
|
27
|
-
flex: 1;
|
|
28
|
-
overflow-y: auto;
|
|
29
|
-
display: flex;
|
|
30
|
-
flex-direction: row;
|
|
31
|
-
align-items: center;
|
|
32
|
-
gap: 10px;
|
|
24
|
+
const StyledModalContentContainer = styled.div `
|
|
25
|
+
width: 100%;
|
|
26
|
+
padding: 10px;
|
|
27
|
+
flex: 1;
|
|
28
|
+
overflow-y: auto;
|
|
29
|
+
display: flex;
|
|
30
|
+
flex-direction: row;
|
|
31
|
+
align-items: center;
|
|
32
|
+
gap: 10px;
|
|
33
33
|
`;
|
|
34
34
|
// *** Componente della modale di conferma ***
|
|
35
35
|
const TMConfirmModal = ({ isOpen, title, message, okButtonText = 'OK', cancelButtonText = 'Annulla', onConfirm, onCancel, onClose }) => {
|
|
@@ -2,11 +2,11 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
2
2
|
import { useEffect, useRef, useState } from 'react';
|
|
3
3
|
import styled from 'styled-components';
|
|
4
4
|
import { IconRight } from '../../helper/TMIcons';
|
|
5
|
-
const StyledContextMenuContainer = styled.div `
|
|
6
|
-
display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; z-index: 300; position: fixed; top: ${props => `${props.$top}px`}; left: ${props => `${props.$left}px`}; right: ${props => `${props.$right}px`}; bottom: ${props => `${props.$bottom}px`}; width: max-content; height: max-content; background-color: white; box-shadow: 1px 1px 2px #00000040;
|
|
5
|
+
const StyledContextMenuContainer = styled.div `
|
|
6
|
+
display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; z-index: 300; position: fixed; top: ${props => `${props.$top}px`}; left: ${props => `${props.$left}px`}; right: ${props => `${props.$right}px`}; bottom: ${props => `${props.$bottom}px`}; width: max-content; height: max-content; background-color: white; box-shadow: 1px 1px 2px #00000040;
|
|
7
7
|
`;
|
|
8
|
-
const StyledContextMenuItem = styled.div `
|
|
9
|
-
cursor: ${props => !props.$disabled ? 'pointer' : 'default'}; display: flex; align-items: center; gap: 5px; transition: ease 100ms; padding: 5px; background-color: ${props => props.$isSelected && '#e9e9e9'}; width: 100%; height: 100%; color: ${props => props.$disabled && '#d0d0d0'}; &:hover { background-color: ${props => !props.$disabled && '#e9e9e9'} ; }
|
|
8
|
+
const StyledContextMenuItem = styled.div `
|
|
9
|
+
cursor: ${props => !props.$disabled ? 'pointer' : 'default'}; display: flex; align-items: center; gap: 5px; transition: ease 100ms; padding: 5px; background-color: ${props => props.$isSelected && '#e9e9e9'}; width: 100%; height: 100%; color: ${props => props.$disabled && '#d0d0d0'}; &:hover { background-color: ${props => !props.$disabled && '#e9e9e9'} ; }
|
|
10
10
|
`;
|
|
11
11
|
const TMContextMenu = ({ items = [], coords = { x: 0, y: 0 }, subMenuDir = 'right', }) => {
|
|
12
12
|
// Coordinates for sub-menus
|
|
@@ -23,32 +23,32 @@ export const useContextMenu = () => {
|
|
|
23
23
|
return { clicked, setClicked, points, setPoints };
|
|
24
24
|
};
|
|
25
25
|
// #endregion
|
|
26
|
-
export const Container = styled.div `
|
|
27
|
-
position: absolute;
|
|
28
|
-
padding: 5px 5px;
|
|
29
|
-
background-color: white;
|
|
30
|
-
width: max-content;
|
|
31
|
-
height: max-content;
|
|
32
|
-
border-radius: 2px;
|
|
33
|
-
display: flex;
|
|
34
|
-
flex-direction: column;
|
|
35
|
-
justify-content: flex-start;
|
|
36
|
-
align-items: center;
|
|
37
|
-
box-shadow: 2px 2px 10px #00000030;
|
|
38
|
-
z-index: 2;
|
|
39
|
-
top: ${(props) => props.$top || 0}px;
|
|
40
|
-
left: ${(props) => props.$left || 0}px;
|
|
26
|
+
export const Container = styled.div `
|
|
27
|
+
position: absolute;
|
|
28
|
+
padding: 5px 5px;
|
|
29
|
+
background-color: white;
|
|
30
|
+
width: max-content;
|
|
31
|
+
height: max-content;
|
|
32
|
+
border-radius: 2px;
|
|
33
|
+
display: flex;
|
|
34
|
+
flex-direction: column;
|
|
35
|
+
justify-content: flex-start;
|
|
36
|
+
align-items: center;
|
|
37
|
+
box-shadow: 2px 2px 10px #00000030;
|
|
38
|
+
z-index: 2;
|
|
39
|
+
top: ${(props) => props.$top || 0}px;
|
|
40
|
+
left: ${(props) => props.$left || 0}px;
|
|
41
41
|
`;
|
|
42
|
-
export const MenuOption = styled.div `
|
|
43
|
-
width: 100%;
|
|
44
|
-
height: 20px;
|
|
45
|
-
padding: 3px;
|
|
46
|
-
cursor: pointer;
|
|
47
|
-
font-size: ${FontSize.defaultFontSize};
|
|
48
|
-
|
|
49
|
-
&:hover {
|
|
50
|
-
color: ${Colors.primary};
|
|
51
|
-
}
|
|
42
|
+
export const MenuOption = styled.div `
|
|
43
|
+
width: 100%;
|
|
44
|
+
height: 20px;
|
|
45
|
+
padding: 3px;
|
|
46
|
+
cursor: pointer;
|
|
47
|
+
font-size: ${FontSize.defaultFontSize};
|
|
48
|
+
|
|
49
|
+
&:hover {
|
|
50
|
+
color: ${Colors.primary};
|
|
51
|
+
}
|
|
52
52
|
`;
|
|
53
53
|
const TMContextMenuOLD = ({ menuData, top, left, onMenuItemClick }) => {
|
|
54
54
|
return (_jsx(_Fragment, { children: _jsx(Container, { "$top": top, "$left": left, children: menuData.map((item, index) => (_jsx(MenuOption, { onClick: (e) => onMenuItemClick?.(e.target.innerText), children: item.text }, index))) }) }));
|