@@ -54,9 +54,7 @@ const MigrationLogViewer = ({ serverPath }: LogsType) => {
5454 const [ zoomLevel , setZoomLevel ] = useState ( 1 ) ;
5555
5656 const newMigrationData = useSelector ( ( state : RootState ) => state ?. migration ?. newMigrationData ) ;
57- const selectedOrganisation = useSelector (
58- ( state : RootState ) => state ?. authentication ?. selectedOrganisation
59- ) ;
57+
6058 const user = useSelector ( ( state : RootState ) => state ?. authentication ?. user ) ;
6159
6260 const dispatch = useDispatch ( ) ;
@@ -157,11 +155,6 @@ const MigrationLogViewer = ({ serverPath }: LogsType) => {
157155 * Zooms out the logs container.
158156 */
159157 const handleZoomOut = ( ) => {
160- // const logsContainer = document.querySelector('.logs-magnify') as HTMLElement;
161- // if (logsContainer) {
162- // setZoomLevel(prevZoomLevel => prevZoomLevel - 0.1);
163- // logsContainer.style.transform = `scale(${zoomLevel})`;
164- // }
165158 setZoomLevel ( ( prevZoomLevel ) => {
166159 const newZoomLevel = Math . max ( prevZoomLevel - 0.1 , 0.6 ) ; // added minimum level for zoom out
167160 return newZoomLevel ;
@@ -261,26 +254,11 @@ const MigrationLogViewer = ({ serverPath }: LogsType) => {
261254 >
262255 { logs . map ( ( log , index ) => {
263256 try {
264- //const logObject = JSON.parse(log);
265257 const { level, timestamp, message } = log ;
266258
267- return newMigrationData ?. destination_stack ?. migratedStacks ?. includes (
268- newMigrationData ?. destination_stack ?. selectedStack ?. value
269- ) ? (
270- < div
271- key = { `${ index ?. toString } ` }
272- style = { logStyles [ level || '' ] || logStyles . info }
273- className = "log-entry text-center"
274- >
275- < div className = "log-message generic-log-message" >
276- Migration has already done in selected stack. Please create a new project.
277- </ div >
278- </ div >
279- ) : (
259+ return (
280260 < div
281261 key = { index }
282- // style={logStyles[level || ''] || logStyles.info}
283- // className="log-entry logs-bg"
284262 >
285263 { message === 'Migration logs will appear here once the process begins.' ? (
286264 < div
0 commit comments