@topconsultnpm/sdkui-react-beta 6.12.112 → 6.12.114
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/Designer bianco.svg +1 -0
- package/lib/assets/Designer blu.svg +1 -0
- package/lib/assets/Orchestrator bianco.svg +1 -0
- package/lib/assets/Orchestrator blu.svg +1 -0
- package/lib/assets/Surfer bianco.svg +1 -0
- package/lib/assets/Surfer blu.svg +1 -0
- package/lib/assets/six.svg +1 -0
- package/lib/components/base/TMFileManager.js +9 -1
- package/lib/components/base/TMSpinner.js +2 -2
- package/lib/components/forms/Login/TMLoginForm.js +11 -2
- package/lib/components/grids/TMBlogs.js +1 -1
- package/lib/components/sidebar/TMHeader.js +1 -1
- package/package.json +1 -1
@@ -2,9 +2,9 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import React from 'react';
|
3
3
|
import ReactDOM from 'react-dom/client';
|
4
4
|
import { FontSize } from '../../utils/theme';
|
5
|
-
import logoSix from '../../assets/
|
5
|
+
import logoSix from '../../assets/six.svg';
|
6
6
|
const Spinner = ({ backgroundColor = 'transparent', description = '', fontSize = FontSize.defaultFontSize, width = 'fit-content' }) => {
|
7
|
-
return (_jsx("div", { className: 'tm-spinner-container', style: { backgroundColor: backgroundColor }, children: _jsxs("div", { className: 'tm-spinner-wrapper', style: { width: width }, children: [_jsxs("div", { style: { position: 'relative', width: '80px', height: '80px' }, children: [_jsx("img", { style: { position: 'absolute', top: '50%', left: '50%', transform: 'translate(-50%, -50%)' }, src: logoSix, width:
|
7
|
+
return (_jsx("div", { className: 'tm-spinner-container', style: { backgroundColor: backgroundColor }, children: _jsxs("div", { className: 'tm-spinner-wrapper', style: { width: width }, children: [_jsxs("div", { style: { position: 'relative', width: '80px', height: '80px' }, children: [_jsx("img", { style: { position: 'absolute', top: '50%', left: '50%', transform: 'translate(-50%, -50%)' }, src: logoSix, width: 40, alt: "" }), _jsxs("div", { className: "tm-spinner", style: { position: 'absolute', top: '50%', left: '50%', transform: 'translate(-50%, -50%)' }, children: [_jsx("div", {}), _jsx("div", {}), _jsx("div", {}), _jsx("div", {}), _jsx("div", {}), _jsx("div", {}), _jsx("div", {}), _jsx("div", {})] })] }), _jsx("div", { style: { fontSize: fontSize, textAlign: 'center' }, className: 'tm-spinner-description', children: description })] }) }));
|
8
8
|
};
|
9
9
|
class TMSpinner {
|
10
10
|
static show({ description, backgroundColor, fontSize } = { backgroundColor: 'transparent', description: '', fontSize: FontSize.defaultFontSize }) {
|
@@ -13,7 +13,9 @@ import Menu from "./Menu";
|
|
13
13
|
import TextBox from "./TextBox";
|
14
14
|
import Chooser from "./Chooser";
|
15
15
|
import SelectBox from "./SelectBox";
|
16
|
-
import
|
16
|
+
import six_SURFER from '../../../assets/Surfer blu.svg';
|
17
|
+
import six_DESIGNER from '../../../assets/Designer blu.svg';
|
18
|
+
import six_ORCHESTRATOR from '../../../assets/Orchestrator blu.svg';
|
17
19
|
import it from '../../../assets/italy.svg';
|
18
20
|
import en from '../../../assets/united-kingdom.svg';
|
19
21
|
import es from '../../../assets/spain.svg';
|
@@ -567,7 +569,14 @@ const TMLoginForm = (props) => {
|
|
567
569
|
window.removeEventListener('keydown', handleKeyDown);
|
568
570
|
};
|
569
571
|
}, [showContinueBtn, disableContinueBtn, showLoginBtn, disableLoginBtn, nextStepHandler, loginHandler]);
|
570
|
-
|
572
|
+
const welcomeLogo = useMemo(() => {
|
573
|
+
switch (SDK_Globals.appModule) {
|
574
|
+
case AppModules.ORCHESTRATOR: return six_ORCHESTRATOR;
|
575
|
+
case AppModules.DESIGNER: return six_DESIGNER;
|
576
|
+
default: return six_SURFER;
|
577
|
+
}
|
578
|
+
}, [SDK_Globals.appModule]);
|
579
|
+
return (_jsxs(StyledWrapper, { children: [!isMobile && _jsxs(StyledVersionContainer, { children: [_jsxs(StyledVersion, { children: [_jsxs(StyledVersionName, { children: [_jsx("span", { style: { color: TMColors.primary }, children: "\u25CF" }), SDK_Globals.appModule] }), _jsxs("p", { children: ["v.", SDK_Globals.appVersion] })] }), _jsxs(StyledVersion, { children: [_jsxs(StyledVersionName, { children: [_jsx("span", { style: { color: TMColors.tertiary }, children: "\u25CF" }), "SDKUI"] }), _jsxs("p", { children: ["v.", SDK_Globals.sdkuiVersion] })] }), _jsxs(StyledVersion, { children: [_jsxs(StyledVersionName, { children: [_jsx("span", { style: { color: TMColors.error }, children: "\u25CF" }), "SDK"] }), _jsxs("p", { children: ["v.", SDK_Globals.sdkVersion] })] })] }), _jsxs(StyledLoginContainer, { "$isMobile": isMobile, children: [_jsxs(StyledLeftSection, { "$isMobile": isMobile, "$isConnector": props.isConnector ?? false, children: [isMobile && _jsxs(StyledTopBar, { children: [_jsx(StyledTitle, { children: SDKUI_Localizator.WelcomeTo.replaceParams('') + ' ' + SDK_Globals.appModule }), _jsx(StyledMobileVersionIcon, { onClick: showVersionPopup, children: _jsx(IconInfo, { fontSize: 20, color: TMColors.primary }) })] }), _jsx(StyledOverlay, { "$isMobile": isMobile, children: _jsx(StyledCustomLogo, { style: { backgroundImage: `url(${showDefaultLogo ? 'logo-default.svg' : 'logo-custom.svg'})` } }) }), (windowHeight === WindowHeight.LARGE || !isMobile) && _jsxs(StyledPoweredByContainer, { "$isMobile": isMobile, children: [" ", showDefaultLogo ? 'Powered by TopConsult' : _jsx("img", { src: "/logo-default.svg", alt: "Logo", width: isMobile ? 50 : 100 }), " "] })] }), _jsxs(StyledRightSection, { "$isMobile": isMobile, children: [((((getDeviceType() === 'desktop' || isDesktop || isTablet) && windowHeight !== WindowHeight.SMALL)) && !isMobile) && _jsxs(StyledLogoContainer, { "$isMobile": isMobile, children: [_jsx(StyledWelcomeText, { children: SDKUI_Localizator.WelcomeTo.replaceParams('') }), _jsx(StyledLogo, { children: _jsx("img", { src: welcomeLogo, alt: "six", height: 60 }) })] }), _jsxs(StyledToolbarContainer, { children: [_jsx(StyledLanguageChooser, { onClick: () => setShowCultureIDs(true), children: _jsx(TMTooltip, { content: SDKUI_Localizator.CultureID, children: _jsx("img", { src: getCultureIDImg(), alt: "Lang", width: 25, height: 25 }) }) }), loginStep !== 3 && _jsx(TMButton, { btnStyle: "icon", onClick: () => setShowRapidAccess(true), icon: _jsx(IconFastAccess, { fontSize: 20 }), caption: LOGINLocalizator.QuickAccess }), showPasswordOperations && _jsx(TMButton, { disabled: disablePasswordOperations, btnStyle: "icon", onClick: () => setShowChangePassword(true), icon: _jsx(IconPasswordOutline, { fontSize: 19 }), caption: SDKUI_Localizator.ChangePassword })] }), _jsxs(StyledFormContainer, { "$isMobile": isMobile, "$windowHeight": windowHeight, children: [loginStep === 1 &&
|
571
580
|
_jsxs(StyledStepContainer, { children: [_jsx(Chooser, { isDropDown: isDesktop, dataSource: props.endpoints, value: 'Description', columns: accessPointChooserColumns, additionalIcons: accessPointAdditionalIcons, icon: _jsx(IconAccessPoint, {}), label: SDKUI_Localizator.Endpoint, onSelectionChanged: (ep) => { setEndpoint(ep); setDcmtArchive(undefined); }, validationItems: fieldValidations('endpoint'), selectedRow: endpoint ?? undefined }), _jsx(Chooser, { isDropDown: isDesktop, dataSource: dcmtArchives, value: 'description', columns: dcmtArchiveChooserColumns, icon: _jsx(IconArchiveDoc, {}), label: SDKUI_Localizator.ArchiveID, onSelectionChanged: (arch) => setDcmtArchive(arch), validationItems: fieldValidations('dcmtArchive'), disabled: !endpoint, selectedRow: dcmtArchive ?? undefined })] }), loginStep === 2 &&
|
572
581
|
_jsxs(StyledStepContainer, { "$windowHeight": windowHeight, style: { marginTop: '20px' }, children: [_jsxs(StyledSummaryContainer, { style: { position: 'absolute', top: getTopOffset(windowHeight, isMobile, isTablet), left: '50%', transform: 'translateX(-50%)', width: 'max-content' }, children: [_jsxs(StyledDescription, { children: [_jsx(TMTooltip, { content: SDKUI_Localizator.Endpoint, children: _jsx(IconAccessPoint, { color: TMColors.primary, fontSize: 16 }) }), _jsx("p", { children: endpoint?.Description })] }), _jsxs(StyledDescription, { children: [_jsx(TMTooltip, { content: SDKUI_Localizator.ArchiveID, children: _jsx(IconArchiveDoc, { color: TMColors.primary, fontSize: 16 }) }), _jsx("p", { children: dcmtArchive?.description })] })] }), _jsx(SelectBox, { value: authMode, options: authModeOptions, onValueChanged: (value) => setAuthMode(value), validationItems: fieldValidations('authenticationMode'), icon: _jsx(IconLogin, {}), label: SDKUI_Localizator.AuthMode }), _jsxs(StyledCredentialWrapper, { children: [authMode === AuthenticationModes.WindowsThroughTopMedia && _jsx(TextBox, { ref: authDomainRef, value: authDomain, onValueChanged: (e) => setAuthDomain(e), validationItems: fieldValidations('authDomain'), type: "text", icon: _jsx(IconWeb, {}), label: SDKUI_Localizator.Domain }), authMode !== AuthenticationModes.MSAzure && _jsx(CeredentialContainer, { isMobile: isMobile, ref: usernameRef, secondaryRef: passwordRef, usernameValidator: fieldValidations('username'), passwordValidator: fieldValidations('password'), authMode: authMode, username: username, password: password, onUsernameChanged: (un) => setUsername(un), onPasswordChanged: (ps) => setPassword(ps) }), authMode === AuthenticationModes.TopMediaOnBehalfOf &&
|
573
582
|
_jsxs(StyledCredentialWrapper, { children: [_jsx(TextBox, { value: authDomain, ref: authDomainRef, onValueChanged: (e) => setAuthDomain(e), validationItems: fieldValidations('authDomain'), type: "text", icon: _jsx(IconWeb, {}), label: SDKUI_Localizator.Domain }), _jsx(CeredentialContainer, { isMobile: isMobile, ref: usernameOnBehalfOfRef, secondaryRef: passwordOnBehalfOfRRef, usernameValidator: fieldValidations('usernameOnBehalfOf'), passwordValidator: fieldValidations('passwordOnBehalfOf'), authMode: AuthenticationModes.TopMediaOnBehalfOf, username: usernameOnBehalf, password: passwordOnBehalf, onUsernameChanged: (un) => setUsernameOnBehalf(un), onPasswordChanged: (ps) => setPasswordOnBehalf(ps) })] })] }), authMode !== AuthenticationModes.TopMediaWithMFA &&
|
@@ -606,6 +606,6 @@ const TMBlogs = (props) => {
|
|
606
606
|
minWidth: isMobile ? '90px' : '120px',
|
607
607
|
width: isMobile ? '90px' : '150px',
|
608
608
|
height: '29px',
|
609
|
-
} }))] }) }) })), _jsxs("div", { style: { height: `calc(100% - ${currentHeader && !isHeaderHidden ? '50px' : '0px'})`, width: "100%", overflow: 'auto', display: 'block' }, children: [_jsx("div", { style: { display: renderMode === 'thumbnails' ? 'block' : 'none', width: "100%", height: "100%" },
|
609
|
+
} }))] }) }) })), _jsxs("div", { style: { height: `calc(100% - ${currentHeader && !isHeaderHidden ? '50px' : '0px'})`, width: "100%", overflow: 'auto', display: 'block' }, onContextMenu: onContextMenu, children: [_jsx("div", { style: { display: renderMode === 'thumbnails' ? 'block' : 'none', width: "100%", height: "100%" }, children: ThumbnailView() }), _jsx("div", { style: { display: renderMode === 'details' ? 'block' : 'none', width: "100%", height: "100%" }, children: DataGridView() }), anchorEl && _jsx(ContextMenu, { ref: contextMenuRef, dataSource: contextMenuItems, target: anchorEl, onHiding: closeContextMenu })] }), (showDcmtForm && focusedAttachment && focusedAttachment.TID && focusedAttachment.DID) && _jsx(TMDcmtForm, { TID: Number(focusedAttachment.TID), DID: Number(focusedAttachment.DID), layoutMode: LayoutModes.Update, onClose: onCloseDcmtForm, isClosable: true, titleModal: SDKUI_Localizator.Attachment + ": " + focusedAttachment.fileName, isModal: true, showPreview: !isMobile, showBoard: !isMobile, widthModal: "95%", heightModal: "95%" })] }) });
|
610
610
|
};
|
611
611
|
export default TMBlogs;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
2
2
|
import { useState, useEffect, useRef } from 'react';
|
3
|
-
import six from '../../assets/
|
3
|
+
import six from '../../assets/six.svg';
|
4
4
|
import { IconBxInfo, IconCloseOutline, IconLogout, IconPassword, IconSearch, IconSettings, IconUserProfile, SDKUI_Localizator } from '../../helper';
|
5
5
|
import styled from 'styled-components';
|
6
6
|
import { SDK_Globals, AuthenticationModes } from '@topconsultnpm/sdk-ts-beta';
|