@integry/sdk 4.5.24 → 4.5.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@integry/sdk",
3
- "version": "4.5.24",
3
+ "version": "4.5.26",
4
4
  "description": "Integry SDK",
5
5
  "main": "dist/umd/index.umd.js",
6
6
  "module": "dist/esm/index.csm.js",
@@ -8,7 +8,7 @@ import { isScrolledIntoView } from '@/utils/common';
8
8
  import { searchJSON } from '@/utils/searchJson';
9
9
  import { Input } from '@/components/Input';
10
10
  import { createElement } from 'preact/compat';
11
- import { createRoot } from 'react-dom/client';
11
+ import { renderToString } from 'react-dom/server';
12
12
  import { TagOptions } from '../TagOptions';
13
13
  import { ThreeDotLoader } from '../../ThreeDotLoader';
14
14
  import styles from './styles.module.scss';
@@ -220,22 +220,6 @@ const FieldDropdown = (props: FieldMenuProps) => {
220
220
  });
221
221
  }
222
222
 
223
- const PortalWrapper = () => {
224
- const reactRoot = useRef<HTMLDivElement>(null);
225
-
226
- useEffect(() => {
227
- if (reactRoot.current) {
228
- const root = createRoot(reactRoot.current);
229
- root.render(tagsComponentRender);
230
- }
231
- }, []);
232
-
233
- return html`<div ref=${reactRoot}></div>`;
234
- };
235
-
236
- // eslint-disable-next-line no-console
237
- console.log(PortalWrapper);
238
-
239
223
  return html` <div
240
224
  class=${`${styles.tagMenu} ${enableSearch ? styles.tagMenuWithSearch : ''}`}
241
225
  style=${parentContainer && tagMenyStyleRef?.current
@@ -361,7 +345,7 @@ const FieldDropdown = (props: FieldMenuProps) => {
361
345
  </div>`
362
346
  : html` <div className="${styles.mappedFieldMenu}">
363
347
  ${tagsComponent
364
- ? html`<${PortalWrapper} />`
348
+ ? html`<div>${renderToString(tagsComponentRender)}</div>`
365
349
  : html`${Object.keys(
366
350
  !isEditable ? searchJSON(tags, searchValue) : tags,
367
351
  ).length > 0