From 2989f93e9300b195459057bd03b3a8104619b1f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Goran=20Alkovi=C4=87?= <77000136+goranalkovic-infinum@users.noreply.github.com> Date: Fri, 5 Jul 2024 08:49:00 +0200 Subject: [PATCH] fix docusaurus build --- .../components/component-showcase.js | 53 ++++++++++--------- 1 file changed, 29 insertions(+), 24 deletions(-) diff --git a/website/ui-components/components/component-showcase.js b/website/ui-components/components/component-showcase.js index bd9d1e2a9..4d0360bf9 100644 --- a/website/ui-components/components/component-showcase.js +++ b/website/ui-components/components/component-showcase.js @@ -1,6 +1,7 @@ import { useState, useRef } from 'react'; import { Button } from '@eightshift/ui-components'; import { clsx } from 'clsx'; +import BrowserOnly from '@docusaurus/BrowserOnly'; export const ComponentShowcase = ({ children, @@ -14,30 +15,34 @@ export const ComponentShowcase = ({ const ref = useRef(); return ( -
-
- {typeof children === 'function' && children(data, setData)} - {typeof children !== 'function' && children} -
- -
- {preContent && preContent(data, setData, ref)} - {resettable && ( - - )} -
-
+ {typeof children === 'function' && children(data, setData)} + {typeof children !== 'function' && children} + + +
+ {preContent && preContent(data, setData, ref)} + {resettable && ( + + )} +
+ + )} + ); };