@orchestrator-ui/orchestrator-ui-components
Version:
Library of UI Components used to display the workflow orchestrator frontend
10 lines (8 loc) • 303 B
text/typescript
import { useOrchestratorTheme } from './useOrchestratorTheme';
import type { WfoTheme } from './useOrchestratorTheme';
export function useWithOrchestratorTheme<T>(
getStylesFunction: (theme: WfoTheme) => T,
) {
const wfoTheme = useOrchestratorTheme();
return getStylesFunction(wfoTheme);
}