Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified client/src/assets/kadena-kda-logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 1 addition & 8 deletions client/src/components/NodeGridTable/CustomTooltip.jsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Tooltip2 } from '@blueprintjs/popover2';
import { fluxos_version_string } from 'main/flux_version';
import { gethelp, getreq__cumulus, getreq__nimbus, getreq__stratus, getreq__fractus } from 'content/index';
import { gethelp, getreq__cumulus, getreq__nimbus, getreq__stratus } from 'content/index';

export const CustomTooltip = ({ componentName, displayName, gstore }) => {
let Component;
Expand Down Expand Up @@ -308,12 +308,5 @@ const InlineRequirementsView = (name, suffix) => (
{suffix}
</td>
</tr>
<tr>
<th className='rq-name'>Fractus</th>
<td>
{getreq__fractus(name)}
{suffix}
</td>
</tr>
</table>
);
4 changes: 2 additions & 2 deletions client/src/components/NodeGridTable/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ export const NodeGridTable = ({
headerName: 'Uptime',
filter: 'agNumberColumnFilter',
cellRenderer: 'uptimeCell',
width: '150px',
width: 150,
minWidth: 100
},
{ field: 'score', headerName: 'Score', filter: 'agTextColumnFilter' },
Expand Down Expand Up @@ -246,7 +246,7 @@ export const NodeGridTable = ({
onFirstDataRendered={autoSizeAll}
maintainColumnOrder={true}
overlayNoRowsTemplate={'<span>No Nodes</span>'}
frameworkComponents={{
components={{
ipCell: IpCell,
tierCell: TierCell,
benchmarkCell: BenchmarkCell,
Expand Down
6 changes: 3 additions & 3 deletions client/src/content/index.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as r from './internal/req_helpers';
import { fluxos_version_desc_parse } from 'main/flux_version';
export { gethelp, getreq, getreq__cumulus, getreq__nimbus, getreq__stratus, getreq__fractus } from './internal/req_helpers';
export { gethelp, getreq, getreq__cumulus, getreq__nimbus, getreq__stratus} from './internal/req_helpers';

export const URL_YOUTUBE = window.gContent.URL_YOUTUBE;
export const URL_TWITTER = window.gContent.URL_TWITTER;
Expand All @@ -25,13 +25,13 @@ r.defreq_wrap('net_up_speed', _reqsObj['net_up_speed']);
export const CC_COLLATERAL_CUMULUS = window.gContent.CC_COLLATERAL_CUMULUS;
export const CC_COLLATERAL_NIMBUS = window.gContent.CC_COLLATERAL_NIMBUS;
export const CC_COLLATERAL_STRATUS = window.gContent.CC_COLLATERAL_STRATUS;
export const CC_COLLATERAL_FRACTUS = window.gContent.CC_COLLATERAL_FRACTUS;
//export const CC_COLLATERAL_FRACTUS = window.gContent.CC_COLLATERAL_FRACTUS;

export const CC_BLOCK_REWARD = window.gContent.CC_BLOCK_REWARD;
export const CC_FLUX_REWARD_CUMULUS = window.gContent.CC_FLUX_REWARD_CUMULUS;
export const CC_FLUX_REWARD_NIMBUS = window.gContent.CC_FLUX_REWARD_NIMBUS;
export const CC_FLUX_REWARD_STRATUS = window.gContent.CC_FLUX_REWARD_STRATUS;
export const CC_FLUX_REWARD_FRACTUS = window.gContent.CC_FLUX_REWARD_FRACTUS;
//export const CC_FLUX_REWARD_FRACTUS = window.gContent.CC_FLUX_REWARD_FRACTUS;
export const CC_PA_REWARD = window.gContent.CC_PA_REWARD;

// export const LATEST_FLUX_VERSION_DESC = fluxos_version_desc_parse(window.gContent.LATEST_FLUX_VERSION);
Expand Down
6 changes: 3 additions & 3 deletions client/src/content/internal/req_helpers.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ export const reqs = {
cumulus: {},
nimbus: {},
stratus: {},
fractus: {}
//fractus: {}
};

export function defhelp(name, desc) {
Expand All @@ -25,7 +25,7 @@ export function defreq_wrap(name, values_obj) {
defreq('cumulus', name, values_obj['C']);
defreq('nimbus', name, values_obj['N']);
defreq('stratus', name, values_obj['S']);
defreq('fractus', name, values_obj['F']);
//defreq('fractus', name, values_obj['F']);
}

export function gethelp(name) {
Expand All @@ -43,7 +43,7 @@ export function getreq(tier, name) {
export const getreq__cumulus = (name) => getreq('cumulus', name);
export const getreq__nimbus = (name) => getreq('nimbus', name);
export const getreq__stratus = (name) => getreq('stratus', name);
export const getreq__fractus = (name) => getreq('fractus', name);
//export const getreq__fractus = (name) => getreq('fractus', name);

/* Help Information to show on toolips */

Expand Down
6 changes: 3 additions & 3 deletions client/src/demo/Demo.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { AppToaster } from 'main/AppToaster';
import { Intent, Spinner } from '@blueprintjs/core';
import { getDemoWallet } from '../main/apidata';
import FailedToLoadDemo from './FailedToLoadDemo';
import { setGAEvent, setGAPageView } from 'g-analytic';
//import { setGAEvent, setGAPageView } from 'g-analytic';

class Demo extends React.Component {
constructor(props) {
Expand All @@ -28,8 +28,8 @@ class Demo extends React.Component {
});
}
if (window) {
setGAEvent({ category: 'Demo page', action: 'visit' });
setGAPageView(window.location.pathname);
//setGAEvent({ category: 'Demo page', action: 'visit' });
//setGAPageView(window.location.pathname);
}
}

Expand Down
8 changes: 4 additions & 4 deletions client/src/guides/GuidesView.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,16 @@ import Accordion from 'react-bootstrap/Accordion';

import { FooterRendered } from 'components/Footer';

import { RequirementsCumulus, RequirementsNimbus, RequirementsStratus, RequirementsFractus } from './NodeRequirements';
import { RequirementsCumulus, RequirementsNimbus, RequirementsStratus } from './NodeRequirements';

import { Container, Row, Col } from 'react-grid-system';
import { setGAEvent, setGAPageView } from 'g-analytic';
//import { setGAEvent, setGAPageView } from 'g-analytic';

class AppGuidesView extends React.Component {
componentDidMount() {
if (window) {
setGAPageView(window.location.pathname);
setGAEvent({ category: 'GuidesPage', action: 'visit' })
//setGAPageView(window.location.pathname);
//setGAEvent({ category: 'GuidesPage', action: 'visit' })
}
}

Expand Down
6 changes: 4 additions & 2 deletions client/src/guides/NodeRequirements/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import './index.scss';

import { Card, Divider, Icon } from '@blueprintjs/core';

import { gethelp, getreq__cumulus, getreq__nimbus, getreq__stratus, getreq__fractus } from 'content/index';
import { CC_COLLATERAL_CUMULUS, CC_COLLATERAL_NIMBUS, CC_COLLATERAL_STRATUS, CC_COLLATERAL_FRACTUS } from 'content/index';
import { gethelp, getreq__cumulus, getreq__nimbus, getreq__stratus } from 'content/index';
import { CC_COLLATERAL_CUMULUS, CC_COLLATERAL_NIMBUS, CC_COLLATERAL_STRATUS } from 'content/index';

/* https://stackoverflow.com/a/2901298 */
function numberWithCommas(x) {
Expand Down Expand Up @@ -104,6 +104,7 @@ export const RequirementsStratus = (
/>
);

/*
export const RequirementsFractus = (
<NodeRequirementsBlock
tierName='FRACTUS'
Expand All @@ -127,3 +128,4 @@ export const RequirementsFractus = (
blockReward='0'
/>
);
*/
58 changes: 20 additions & 38 deletions client/src/home/Header/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { FiCpu, FiHardDrive, FiPackage, FiZap } from 'react-icons/fi';
import { FaWallet, FaWordpress, FaRocket, FaHive } from 'react-icons/fa';

import { LayoutContext } from 'contexts/LayoutContext';
import { useContext, useState } from 'react';
import { useContext } from 'react';

import 'react-circular-progressbar/dist/styles.css';
import { RadialCircularProgressbar } from 'components/RadialCircularProgressbar';
Expand Down Expand Up @@ -105,7 +105,6 @@ function CellTooltip({ children, tooltipContent }) {
}

export function DashboardCells({ gstore: gs, total_donations }) {
const [enableFractusNodesCell, setToggleFractusNodesCell] = useState(false);
const { normalFontSize } = useContext(LayoutContext);

const iconSize = normalFontSize ? '28px' : '22px';
Expand Down Expand Up @@ -189,40 +188,22 @@ export function DashboardCells({ gstore: gs, total_donations }) {
)}
</CellTooltip>

<CellTooltip
tooltipContent={
<TierRewardsProjectionView
rewards={enableFractusNodesCell ? gs.reward_projections.fractus : gs.reward_projections.cumulus}
{/* Cumulus Node Cell - No longer toggleable */}
<CellTooltip tooltipContent={<TierRewardsProjectionView rewards={gs.reward_projections.cumulus} />}>
{(ref, tooltipProps) => (
<Cell
elementRef={ref}
{...tooltipProps}
name='Cumulus Nodes'
value={gs.node_count.cumulus}
icon={<FiZap size={iconSize} />}
iconWrapClassName={`dash-cell__nodes-cumulus${suffixClassName}`}
small={!normalFontSize}
cellHover
/>
}
>
{(ref, tooltipProps) => {
const cellProps = enableFractusNodesCell
? {
name: 'Fractus Nodes',
value: gs.node_count.fractus,
icon: <FiHardDrive size={iconSize} />,
iconWrapClassName: `dash-cell__nodes-fractus${suffixClassName}`
}
: {
name: 'Cumulus Nodes',
value: gs.node_count.cumulus,
icon: <FiZap size={iconSize} />,
iconWrapClassName: `dash-cell__nodes-cumulus${suffixClassName}`
};

return (
<Cell
elementRef={ref}
{...tooltipProps}
{...cellProps}
small={!normalFontSize}
cellHover
toggleBtn={() => setToggleFractusNodesCell((prev) => !prev)}
/>
);
}}
)}
</CellTooltip>

<CellTooltip tooltipContent={<TierRewardsProjectionView rewards={gs.reward_projections.nimbus} />}>
{(ref, tooltipProps) => (
<Cell
Expand All @@ -237,6 +218,7 @@ export function DashboardCells({ gstore: gs, total_donations }) {
/>
)}
</CellTooltip>

<CellTooltip tooltipContent={<TierRewardsProjectionView rewards={gs.reward_projections.stratus} />}>
{(ref, tooltipProps) => (
<Cell
Expand Down Expand Up @@ -273,7 +255,6 @@ export function DashboardCells({ gstore: gs, total_donations }) {
radialSeparatorStyles={{
background: '#181a1b',
width: '2px',
// This needs to be equal to props.strokeWidth
height: `${8}%`
}}
/>
Expand All @@ -284,6 +265,7 @@ export function DashboardCells({ gstore: gs, total_donations }) {
/>
)}
</CellTooltip>

<CellTooltip
tooltipContent={<UtilizationView utilized={gs.utilized.cores} total={gs.total.cores} suffix='vCores' />}
>
Expand All @@ -307,7 +289,6 @@ export function DashboardCells({ gstore: gs, total_donations }) {
radialSeparatorStyles={{
background: '#181a1b',
width: '2px',
// This needs to be equal to props.strokeWidth
height: `${8}%`
}}
/>
Expand All @@ -318,6 +299,7 @@ export function DashboardCells({ gstore: gs, total_donations }) {
/>
)}
</CellTooltip>

<CellTooltip
tooltipContent={<UtilizationView utilized={gs.utilized.ram} total={gs.total.ram} suffix='TB' />}
>
Expand All @@ -341,7 +323,6 @@ export function DashboardCells({ gstore: gs, total_donations }) {
radialSeparatorStyles={{
background: '#181a1b',
width: '2px',
// This needs to be equal to props.strokeWidth
height: `${8}%`
}}
/>
Expand All @@ -352,6 +333,7 @@ export function DashboardCells({ gstore: gs, total_donations }) {
/>
)}
</CellTooltip>

<CellTooltip
tooltipContent={<UtilizationView utilized={gs.utilized.ssd} total={gs.total.ssd} suffix='TB' />}
>
Expand All @@ -375,7 +357,6 @@ export function DashboardCells({ gstore: gs, total_donations }) {
radialSeparatorStyles={{
background: '#181a1b',
width: '2px',
// This needs to be equal to props.strokeWidth
height: `${8}%`
}}
/>
Expand All @@ -386,6 +367,7 @@ export function DashboardCells({ gstore: gs, total_donations }) {
/>
)}
</CellTooltip>

<Cell
name={`Current block height`}
value={gs.fluxBlockHeight}
Expand Down
Loading