@topconsultnpm/sdkui-react 6.19.0-dev1.25 → 6.19.0-dev1.26

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.
@@ -0,0 +1,7 @@
1
+ import { ReactNode } from 'react';
2
+ interface TMToppyMessageProps {
3
+ message: ReactNode;
4
+ titleTooltip?: string;
5
+ }
6
+ declare const TMToppyMessage: (props: TMToppyMessageProps) => import("react/jsx-runtime").JSX.Element;
7
+ export default TMToppyMessage;
@@ -0,0 +1,42 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import styled from 'styled-components';
3
+ import Toppy from '../assets/Toppy-generico.png';
4
+ import TMLayoutContainer from '../components/base/TMLayout';
5
+ const StyledToppyTextContainer = styled.div `
6
+ padding: 22px 8px;
7
+ width: 100%;
8
+ max-width: 300px;
9
+ border: 1px solid #2559A5;
10
+ border-radius: 30px;
11
+ display: flex;
12
+ align-items: center;
13
+ justify-content: center;
14
+ box-sizing: border-box;
15
+ min-height: 100px;
16
+ `;
17
+ const StyledToppyText = styled.p `
18
+ text-align: center;
19
+ color: #2559A5;
20
+ font-size: 1rem;
21
+ user-select: none;
22
+ margin: 0;
23
+ display: -webkit-box;
24
+ -webkit-box-orient: vertical;
25
+ -webkit-line-clamp: 3; /* non è una proprietà standard ma è così diffusa e ben supportata che è considerata una "best practice pragmatica" */
26
+ overflow: hidden;
27
+ text-overflow: ellipsis;
28
+ white-space: normal;
29
+ word-break: break-word;
30
+ line-height: 1.2;
31
+ `;
32
+ const StyledToppyImage = styled.img `
33
+ width: 100%;
34
+ max-width: 120px;
35
+ height: auto;
36
+ display: block;
37
+ `;
38
+ const TMToppyMessage = (props) => {
39
+ const { message, titleTooltip } = props;
40
+ return _jsxs(TMLayoutContainer, { gap: 30, alignItems: 'center', justifyContent: 'center', children: [_jsx(StyledToppyTextContainer, { children: _jsx(StyledToppyText, { title: titleTooltip ? titleTooltip : undefined, children: message }) }), _jsx(StyledToppyImage, { src: Toppy, alt: 'Toppy' })] });
41
+ };
42
+ export default TMToppyMessage;
@@ -9,3 +9,4 @@ export * from './queryHelper';
9
9
  export * from './TMUtils';
10
10
  export * from './TMCommandsContextMenu';
11
11
  export * from './TMConditionalWrapper';
12
+ export * from './TMToppyMessage';
@@ -9,3 +9,4 @@ export * from './queryHelper';
9
9
  export * from './TMUtils';
10
10
  export * from './TMCommandsContextMenu';
11
11
  export * from './TMConditionalWrapper';
12
+ export * from './TMToppyMessage';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@topconsultnpm/sdkui-react",
3
- "version": "6.19.0-dev1.25",
3
+ "version": "6.19.0-dev1.26",
4
4
  "description": "",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1",