mirror of
https://github.com/portainer/portainer.git
synced 2025-07-24 15:59:41 +02:00
feat(helm): helm actions [r8s-259] (#715)
Co-authored-by: James Player <james.player@portainer.io> Co-authored-by: Cara Ryan <cara.ryan@portainer.io> Co-authored-by: stevensbkang <skan070@gmail.com>
This commit is contained in:
parent
dfa32b6755
commit
4ee349bd6b
117 changed files with 4161 additions and 696 deletions
11
app/react/components/Widget/WidgetIcon.tsx
Normal file
11
app/react/components/Widget/WidgetIcon.tsx
Normal file
|
@ -0,0 +1,11 @@
|
|||
import { ReactNode } from 'react';
|
||||
|
||||
import { Icon } from '@@/Icon';
|
||||
|
||||
export function WidgetIcon({ icon }: { icon: ReactNode }) {
|
||||
return (
|
||||
<div className="text-lg inline-flex items-center rounded-full bg-blue-3 text-blue-8 th-dark:bg-gray-9 th-dark:text-blue-3 p-2">
|
||||
<Icon icon={icon} />
|
||||
</div>
|
||||
);
|
||||
}
|
|
@ -1,9 +1,7 @@
|
|||
import clsx from 'clsx';
|
||||
import { PropsWithChildren, ReactNode } from 'react';
|
||||
|
||||
import { Icon } from '@/react/components/Icon';
|
||||
|
||||
import { useWidgetContext } from './Widget';
|
||||
import { WidgetIcon } from './WidgetIcon';
|
||||
|
||||
interface Props {
|
||||
title: ReactNode;
|
||||
|
@ -17,16 +15,12 @@ export function WidgetTitle({
|
|||
className,
|
||||
children,
|
||||
}: PropsWithChildren<Props>) {
|
||||
useWidgetContext();
|
||||
|
||||
return (
|
||||
<div className="widget-header">
|
||||
<div className="row">
|
||||
<span className={clsx('pull-left vertical-center', className)}>
|
||||
<div className="widget-icon">
|
||||
<Icon icon={icon} className="space-right" />
|
||||
</div>
|
||||
<h2 className="text-base m-0">{title}</h2>
|
||||
<WidgetIcon icon={icon} />
|
||||
<h2 className="text-base m-0 ml-1">{title}</h2>
|
||||
</span>
|
||||
<span className={clsx('pull-right', className)}>{children}</span>
|
||||
</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue