How to use @dcos/ui-kit - 10 common examples

To help you get started, we’ve selected a few @dcos/ui-kit examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github dcos / dcos-ui / src / js / components / CollapsibleErrorMessage.js View on Github external
getFixedMessagePart() {
    const { message } = this.props;

    // If not visible, just exit
    if (!message) {
      return null;
    }

    // Render the fixed part of the message
    return (
      <div>
        <span>
          
        </span>
        {message}
      </div>
    );
  }
github dcos / dcos-ui / plugins / services / src / js / pages / task-details / TaskSystemLogsContainer.tsx View on Github external
const params = getLogParameters(task, {
      // This will be added to the name
      postfix: selectedStream &amp;&amp; selectedStream.toLowerCase(),
      filter: { STREAM: selectedStream }
    });

    // This is a hacky way of interacting with the API to be able to download
    // logs with a POST request
    return (
      <a href="{getUrl(task.slave_id," disabled="{!task}">
        
      </a>
    );
  }
github dcos / dcos-ui / plugins / services / src / js / containers / tasks / TaskTable.tsx View on Github external
const getStatusIcon = () =&gt; {
      // inactive
      if (!activeState || transitional) {
        return <span>;
      }

      // success
      if (healthy &amp;&amp; running) {
        return (
          
        );
      }

      // running
      if (unknown &amp;&amp; running) {
        return <span>;
      }

      // danger
      if (dangerState || unhealthy || failing) {
        return (
          </span></span>
github dcos / dcos-ui / plugins / services / src / js / containers / tasks / TaskTable.tsx View on Github external
size={iconSizeXxs}
            color={success}
          /&gt;
        );
      }

      // running
      if (unknown &amp;&amp; running) {
        return <span>;
      }

      // danger
      if (dangerState || unhealthy || failing) {
        return (
          
        );
      }
    };
</span>
github dcos / dcos-ui / src / js / pages / network / virtual-network-detail / VirtualNetworkTaskPage.jsx View on Github external
/&gt;
    );
  } else {
    breadcrumbs = ;
  }

  const dontScroll = dontScrollRoutes.some(regex =&gt;
    regex.test(location.pathname)
  );

  return (
    
      
      
        {props.children}
      
    
  );
};
github dcos / dcos-ui / plugins / services / src / js / components / modals / ServiceRootGroupModal.tsx View on Github external
const errorItems = errorMessages.map((message, index) =&gt; {
      return (
        <li>
          {message}
        </li>
      );
    });
    return (
      <div>
        
              <div>
                
              </div>
              <div>
                <ul>{errorItems}</ul>
              </div>
            </div>
          }
        /&gt;
      
    );
  }
github dcos / dcos-ui / plugins / services / src / js / components / SDKPlanTable.tsx View on Github external
export const getStatusIcon = (status: ServicePlanStatus): React.ReactNode =&gt; {
  switch (status) {
    case "ERROR":
      return (
        
      );
    case "WAITING":
      return (
        
      );
    case "PENDING":
      return (
        
      );
    case "PREPARED":
      return ;
    case "STARTING":
      return ;
    case "STARTED":
      return ;
    case "IN_PROGRESS":
      return ;
    case "COMPLETE":
      return (
github dcos / dcos-ui / src / js / components / CosmosErrorMessage.jsx View on Github external
render() {
    return (
      <div>
        
              <div>
                <div>
                  
                </div>
                <div>{this.getMessage()}</div>
              </div>

              {this.getDetails() &amp;&amp; (
                <div>
                  <ul>{this.getDetails()}</ul>
                </div>
              )}
            </div>
          }
        /&gt;
github dcos / dcos-ui / plugins / nodes / src / js / columns / NodesTableIpColumn.tsx View on Github external
headline: string;
    isActive: boolean;
  }) =&gt; {
    if (!isActive) {
      return (
        
          
            <span title="{headline}">
              Connection to node lost}
              &gt;
                <span>
                  
                </span>
                {headline}
              
            </span>
          
        
      );
    }

    return (
      
        
          <span title="{headline}">{headline}</span>
github dcos / dcos-ui / plugins / nodes / src / js / components / NodesGridDials.tsx View on Github external
data: sliceData.data,
        description: [
          <span>
            {sliceData.usedPercentage}%
          </span>,
          <span>
            {resourceLabel}
          </span>
        ]
      };
    }
    return {
      data: this.getInactiveSliceData(),
      description: (
        <span>
          
        </span>
      )
    };
  },

@dcos/ui-kit

D2iQ UI Kit

Apache-2.0
Latest version published 1 year ago

Package Health Score

51 / 100
Full package analysis

Popular @dcos/ui-kit functions