{message.content}
26 |55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || 1 67 | 2 68 | 3 69 | 4 70 | 5 71 | 6 72 | 7 73 | 8 | 74 | 1x 75 | 1x 76 | 1x 77 | 1x 78 | 1x 79 | 1x 80 | | // text 81 | export const primaryBlue = '#3861ed'; 82 | export const secondaryBlue = '#ebeffd'; 83 | export const primaryGrey = '#6f78ad'; 84 | export const secondaryGrey = '#9ba4d1'; 85 | export const primaryRed = '#dc143c'; 86 | export const secondaryRed = '#ff0000'; 87 | |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || File | 70 |71 | | Statements | 72 |73 | | Branches | 74 |75 | | Functions | 76 |77 | | Lines | 78 |79 | |
|---|---|---|---|---|---|---|---|---|---|
| InstanceBar.jsx | 83 |
84 |
85 | |
86 | 5% | 87 |1/20 | 88 |0% | 89 |0/4 | 90 |0% | 91 |0/9 | 92 |6.25% | 93 |1/16 | 94 |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || 1 67 | 2 68 | 3 69 | 4 70 | 5 71 | 6 72 | 7 73 | 8 74 | 9 75 | 10 76 | 11 77 | 12 78 | 13 79 | 14 80 | 15 81 | 16 | 1x 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 1x 90 | 91 | 92 | 93 | 94 | 95 | 96 | | export const lightTheme = {
97 | primary: '#fff',
98 | secondary: '#ebf0fe',
99 | textPrimary: '#6f759e',
100 | textSecondary: '#a7abcf',
101 | highlight: '#5174ed',
102 | };
103 |
104 | export const darkTheme = {
105 | primary: '#1a1c1e',
106 | secondary: '#2f3234',
107 | textPrimary: '#adb0b6',
108 | textSecondary: '#6b6e70',
109 | highlight: '#f7f9f9',
110 | };
111 | |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || 1 67 | 2 68 | 3 69 | 4 70 | 5 71 | 6 72 | 7 73 | 8 74 | 9 75 | 10 76 | 11 77 | 12 78 | 13 79 | 14 80 | 15 81 | 16 82 | 17 83 | 18 84 | 19 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | | import { configureStore } from '@reduxjs/toolkit';
103 | import performance from './performanceSlice';
104 | import memory from './memorySlice';
105 | import basicActivity from './basicActivitySlice';
106 | import persistence from './persistenceSlice';
107 | import error from './errorSlice';
108 | import global from './globalSlice';
109 |
110 | export const store = configureStore({
111 | reducer: {
112 | global,
113 | performance,
114 | memory,
115 | basicActivity,
116 | persistence,
117 | error,
118 | },
119 | });
120 | |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || 1 67 | 2 68 | 3 69 | 4 70 | 5 71 | 6 72 | 7 73 | 8 74 | 9 75 | 10 76 | 11 77 | 12 78 | 13 79 | 14 80 | 15 81 | 16 82 | 17 83 | 18 84 | 19 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | | import React from 'react';
103 | import { createRoot } from 'react-dom/client';
104 | import App from './App.jsx';
105 | import '../styles.css';
106 | import { store } from './redux/store.js';
107 | import { Provider } from 'react-redux';
108 | import { BrowserRouter } from "react-router-dom"
109 |
110 |
111 | const container = document.getElementById('app');
112 | const root = createRoot(container);
113 | root.render(
114 | <BrowserRouter>
115 | <Provider store={store}>
116 | <App />
117 | </Provider>
118 | </BrowserRouter>
119 | );
120 | |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || 1 67 | 2 68 | 3 69 | 4 70 | 5 71 | 6 72 | 7 73 | 8 74 | 9 75 | 10 76 | 11 77 | 12 78 | 13 79 | 14 80 | 15 81 | 16 | 1x 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | | export const clock = (duration) => { 97 | // Hours, minutes and seconds 98 | const hrs = Math.floor(duration / 3600); 99 | const mins = Math.floor((duration % 3600) / 60); 100 | const secs = Math.floor(duration % 60); 101 | 102 | let clock = ''; 103 | 104 | if (hrs > 0) { 105 | clock += '' + hrs + ':' + (mins < 10 ? '0' : ''); 106 | } 107 | clock += '' + mins + ':' + (secs < 10 ? '0' : ''); 108 | clock += '' + secs; 109 | return clock; 110 | }; 111 | |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || File | 70 |71 | | Statements | 72 |73 | | Branches | 74 |75 | | Functions | 76 |77 | | Lines | 78 |79 | |
|---|---|---|---|---|---|---|---|---|---|
| PersistencePage.jsx | 83 |
84 |
85 | |
86 | 7.69% | 87 |1/13 | 88 |0% | 89 |0/2 | 90 |0% | 91 |0/6 | 92 |10% | 93 |1/10 | 94 |
| Rcslt.jsx | 98 |
99 |
100 | |
101 | 0% | 102 |0/3 | 103 |100% | 104 |0/0 | 105 |0% | 106 |0/2 | 107 |0% | 108 |0/2 | 109 |
| Rlst.jsx | 113 |
114 |
115 | |
116 | 0% | 117 |0/3 | 118 |100% | 119 |0/0 | 120 |0% | 121 |0/2 | 122 |0% | 123 |0/2 | 124 |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || File | 70 |71 | | Statements | 72 |73 | | Branches | 74 |75 | | Functions | 76 |77 | | Lines | 78 |79 | |
|---|---|---|---|---|---|---|---|---|---|
| ErrorsPage.jsx | 83 |
84 |
85 | |
86 | 7.69% | 87 |1/13 | 88 |0% | 89 |0/2 | 90 |0% | 91 |0/6 | 92 |10% | 93 |1/10 | 94 |
| RejectedConnections.jsx | 98 |
99 |
100 | |
101 | 0% | 102 |0/3 | 103 |100% | 104 |0/0 | 105 |0% | 106 |0/2 | 107 |0% | 108 |0/3 | 109 |
| keyspaceMisses.jsx | 113 |
114 |
115 | |
116 | 0% | 117 |0/5 | 118 |100% | 119 |0/0 | 120 |0% | 121 |0/2 | 122 |0% | 123 |0/4 | 124 |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || 1 67 | 2 68 | 3 69 | 4 70 | 5 71 | 6 72 | 7 73 | 8 74 | 9 75 | 10 76 | 11 77 | 12 78 | 13 79 | 14 80 | 15 81 | 16 82 | 17 83 | 18 84 | 19 85 | 20 86 | 21 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | | import { createSlice } from '@reduxjs/toolkit';
107 | import axios from 'axios';
108 |
109 | const initialState = {
110 | totalInstances: [],
111 | };
112 | export const submitForm = (e) => {
113 | e.preventDefault();
114 |
115 | //values need to be dynamic, from input box
116 | axios
117 | .post('http://localhost:3000/newInstance', {
118 | username: 'garrett',
119 | password: 123,
120 | port: 1,
121 | host: '127.0.0.1:6379',
122 | })
123 | .then((res) => console.log(res))
124 | .catch((err) => console.log(err));
125 | };
126 | |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || 1 67 | 2 68 | 3 69 | 4 70 | 5 71 | 6 72 | 7 73 | 8 74 | 9 75 | 10 76 | 11 77 | 12 78 | 13 79 | 14 80 | 15 81 | 16 82 | 17 83 | 18 84 | 19 85 | 20 86 | 21 87 | 22 88 | 23 89 | 24 | 90 | 91 | 92 | 93 | 94 | 1x 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | | import React from 'react';
113 | import { DarkModeToggler } from './StyledComponents/SideBar.js';
114 | import { themeToggle } from '../redux/globalSlice';
115 | import { useDispatch, useSelector } from 'react-redux';
116 |
117 | const Toggler = (props) => {
118 | const dispatch = useDispatch();
119 | const theme = useSelector((state) => state.global.theme);
120 | return (
121 | <DarkModeToggler>
122 | <label>
123 | <input
124 | onChange={() => dispatch(themeToggle())}
125 | type="checkbox"
126 | checked={theme === 'light' ? true : false}
127 | />
128 | <span className="slider"></span>
129 | </label>
130 | </DarkModeToggler>
131 | );
132 | };
133 |
134 | export default Toggler;
135 | |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || File | 70 |71 | | Statements | 72 |73 | | Branches | 74 |75 | | Functions | 76 |77 | | Lines | 78 |79 | |
|---|---|---|---|---|---|---|---|---|---|
| HitRate.jsx | 83 |
84 |
85 | |
86 | 0% | 87 |0/6 | 88 |100% | 89 |0/0 | 90 |0% | 91 |0/3 | 92 |0% | 93 |0/4 | 94 |
| Iops.jsx | 98 |
99 |
100 | |
101 | 0% | 102 |0/3 | 103 |100% | 104 |0/0 | 105 |0% | 106 |0/2 | 107 |0% | 108 |0/2 | 109 |
| Latency.jsx | 113 |
114 |
115 | |
116 | 0% | 117 |0/4 | 118 |100% | 119 |0/0 | 120 |0% | 121 |0/2 | 122 |0% | 123 |0/3 | 124 |
| PerformancePage.jsx | 128 |
129 |
130 | |
131 | 7.69% | 132 |1/13 | 133 |0% | 134 |0/2 | 135 |0% | 136 |0/6 | 137 |10% | 138 |1/10 | 139 |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || File | 70 |71 | | Statements | 72 |73 | | Branches | 74 |75 | | Functions | 76 |77 | | Lines | 78 |79 | |
|---|---|---|---|---|---|---|---|---|---|
| ActivitiesPage.jsx | 83 |
84 |
85 | |
86 | 7.69% | 87 |1/13 | 88 |0% | 89 |0/2 | 90 |0% | 91 |0/6 | 92 |10% | 93 |1/10 | 94 |
| ConnectedClient.jsx | 98 |
99 |
100 | |
101 | 0% | 102 |0/3 | 103 |100% | 104 |0/0 | 105 |0% | 106 |0/2 | 107 |0% | 108 |0/3 | 109 |
| ConnectedSlaves.jsx | 113 |
114 |
115 | |
116 | 0% | 117 |0/3 | 118 |100% | 119 |0/0 | 120 |0% | 121 |0/2 | 122 |0% | 123 |0/3 | 124 |
| Keyspace.jsx | 128 |
129 |
130 | |
131 | 0% | 132 |0/4 | 133 |100% | 134 |0/0 | 135 |0% | 136 |0/2 | 137 |0% | 138 |0/3 | 139 |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || File | 70 |71 | | Statements | 72 |73 | | Branches | 74 |75 | | Functions | 76 |77 | | Lines | 78 |79 | |
|---|---|---|---|---|---|---|---|---|---|
| EvictedKeys.jsx | 83 |
84 |
85 | |
86 | 25% | 87 |1/4 | 88 |100% | 89 |0/0 | 90 |0% | 91 |0/2 | 92 |33.33% | 93 |1/3 | 94 |
| FragRatioGraph.jsx | 98 |
99 |
100 | |
101 | 25% | 102 |1/4 | 103 |100% | 104 |0/0 | 105 |0% | 106 |0/2 | 107 |25% | 108 |1/4 | 109 |
| MemoryPage.jsx | 113 |
114 |
115 | |
116 | 5.88% | 117 |1/17 | 118 |0% | 119 |0/2 | 120 |0% | 121 |0/7 | 122 |7.69% | 123 |1/13 | 124 |
| UsedMemoryGraph.jsx | 128 |
129 |
130 | |
131 | 25% | 132 |1/4 | 133 |100% | 134 |0/0 | 135 |0% | 136 |0/2 | 137 |33.33% | 138 |1/3 | 139 |
55 | Press n or j to go to the next uncovered block, b, p or k for the previous block. 56 |
57 | 58 || 1 67 | 2 68 | 3 69 | 4 70 | 5 71 | 6 72 | 7 73 | 8 74 | 9 75 | 10 76 | 11 77 | 12 78 | 13 79 | 14 80 | 15 81 | 16 82 | 17 83 | 18 84 | 19 85 | 20 86 | 21 87 | 22 88 | 23 89 | 24 90 | 25 91 | 26 | 92 | 93 | 94 | 95 | 96 | 1x 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | | import React from 'react';
117 | import { Page, HomeButton } from './StyledComponents/HomePage';
118 | import url from './StyledComponents/homeImage.svg';
119 | import { useDispatch } from 'react-redux';
120 | import { showForm } from '../redux/globalSlice';
121 | const HomePage = (prop) => {
122 | const dispatch = useDispatch();
123 | return (
124 | <Page>
125 | <div className="container">
126 | <h1 className="title">Welcome to RediSee</h1>
127 | <h3 className="subtitle">
128 | Get live data from your redis databe with this lightweight monitoring
129 | tool
130 | </h3>
131 | <HomeButton onClick={() => dispatch(showForm())}>
132 | Connect now
133 | </HomeButton>
134 | </div>
135 | <img src={url} alt="Loading" style={{ height: '95%' }} />
136 | </Page>
137 | );
138 | };
139 |
140 | export default HomePage;
141 | |