@frontify/fondue 12.0.0-beta.87 → 12.0.0-beta.88

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.
@@ -1,16 +1,21 @@
1
- import t from "react";
2
- import { MentionCombobox as e } from "@udecode/plate";
3
- import { filterItems as m } from "./helpers/filterItems.es.js";
4
- import { MentionComboboxItem as r } from "./MentionCombobox/MentionComboboxItem.es.js";
5
- import { MentionComboboxStyles as i } from "./MentionCombobox/MentionComboboxStyles.es.js";
6
- const b = (o) => () => /* @__PURE__ */ t.createElement(e, {
7
- items: o,
8
- filter: m,
9
- onRenderItem: r,
10
- styles: i,
1
+ import o from "react";
2
+ import { MentionCombobox as m, autoUpdate as r } from "@udecode/plate";
3
+ import { filterItems as n } from "./helpers/filterItems.es.js";
4
+ import { MentionComboboxItem as i } from "./MentionCombobox/MentionComboboxItem.es.js";
5
+ import { MentionComboboxStyles as l } from "./MentionCombobox/MentionComboboxStyles.es.js";
6
+ const b = (t) => () => /* @__PURE__ */ o.createElement(m, {
7
+ items: t,
8
+ filter: n,
9
+ onRenderItem: i,
10
+ styles: l,
11
11
  classNames: {
12
12
  item: "tw-group",
13
13
  highlightedItem: "tw-group"
14
+ },
15
+ floatingOptions: {
16
+ whileElementsMounted(...e) {
17
+ return r(...e, { animationFrame: !0 });
18
+ }
14
19
  }
15
20
  });
16
21
  export {
@@ -1 +1 @@
1
- {"version":3,"file":"MentionInline.es.js","sources":["../../../../../src/components/RichTextEditor/Plugins/MentionPlugin/MentionInline.tsx"],"sourcesContent":["/* (c) Copyright Frontify Ltd., all rights reserved. */\n\nimport React from 'react';\nimport { MentionCombobox } from '@udecode/plate';\nimport { MentionComboboxItem, MentionComboboxStyles } from './MentionCombobox';\nimport { MentionableItems } from './types';\nimport { filterItems } from './helpers';\n\n// eslint-disable-next-line react/display-name\nexport const MentionInline = (items: MentionableItems) => () => {\n return (\n <MentionCombobox\n items={items}\n filter={filterItems}\n onRenderItem={MentionComboboxItem}\n styles={MentionComboboxStyles}\n classNames={{\n item: 'tw-group',\n highlightedItem: 'tw-group',\n }}\n />\n );\n};\n"],"names":["MentionInline","items","React","MentionCombobox","filterItems","MentionComboboxItem","MentionComboboxStyles"],"mappings":";;;;;AASa,MAAAA,IAAgB,CAACC,MAA4B,MAEjD,gBAAAC,EAAA,cAAAC,GAAA;AAAA,EACG,OAAAF;AAAA,EACA,QAAQG;AAAA,EACR,cAAcC;AAAA,EACd,QAAQC;AAAA,EACR,YAAY;AAAA,IACR,MAAM;AAAA,IACN,iBAAiB;AAAA,EACrB;AAAA,CACJ;"}
1
+ {"version":3,"file":"MentionInline.es.js","sources":["../../../../../src/components/RichTextEditor/Plugins/MentionPlugin/MentionInline.tsx"],"sourcesContent":["/* (c) Copyright Frontify Ltd., all rights reserved. */\n\nimport React from 'react';\nimport { MentionCombobox, autoUpdate } from '@udecode/plate';\nimport { MentionComboboxItem, MentionComboboxStyles } from './MentionCombobox';\nimport { MentionableItems } from './types';\nimport { filterItems } from './helpers';\n\n// eslint-disable-next-line react/display-name\nexport const MentionInline = (items: MentionableItems) => () => {\n return (\n <MentionCombobox\n items={items}\n filter={filterItems}\n onRenderItem={MentionComboboxItem}\n styles={MentionComboboxStyles}\n classNames={{\n item: 'tw-group',\n highlightedItem: 'tw-group',\n }}\n floatingOptions={{\n whileElementsMounted(...args) {\n return autoUpdate(...args, { animationFrame: true });\n },\n }}\n />\n );\n};\n"],"names":["MentionInline","items","React","MentionCombobox","filterItems","MentionComboboxItem","MentionComboboxStyles","args","autoUpdate"],"mappings":";;;;;AASa,MAAAA,IAAgB,CAACC,MAA4B,MAEjD,gBAAAC,EAAA,cAAAC,GAAA;AAAA,EACG,OAAAF;AAAA,EACA,QAAQG;AAAA,EACR,cAAcC;AAAA,EACd,QAAQC;AAAA,EACR,YAAY;AAAA,IACR,MAAM;AAAA,IACN,iBAAiB;AAAA,EACrB;AAAA,EACA,iBAAiB;AAAA,IACb,wBAAwBC,GAAM;AAC1B,aAAOC,EAAW,GAAGD,GAAM,EAAE,gBAAgB,GAAM,CAAA;AAAA,IACvD;AAAA,EACJ;AAAA,CACJ;"}
package/dist/index.cjs.js CHANGED
@@ -59,7 +59,7 @@ Shift+Ctrl+Return`:"Already at maximum numbers of columns"),onMouseDown:L=>m?w.g
59
59
  `],item:ck,highlightedItem:[...ck,`
60
60
  background: var(--box-neutral-color);
61
61
  color: var(--box-neutral-inverse-color-hover);
62
- `]},TC0=e=>l=>l.text.toLowerCase().includes(e.toLowerCase()),jC0=e=>()=>t.default.createElement(w.MentionCombobox,{items:e,filter:TC0,onRenderItem:HC0,styles:zC0,classNames:{item:"tw-group",highlightedItem:"tw-group"}}),VC0={options:{trigger:"@",createMentionNode:e=>({value:e.text,key:e.key,category:e.data.category})}},DC0={root:[`
62
+ `]},TC0=e=>l=>l.text.toLowerCase().includes(e.toLowerCase()),jC0=e=>()=>t.default.createElement(w.MentionCombobox,{items:e,filter:TC0,onRenderItem:HC0,styles:zC0,classNames:{item:"tw-group",highlightedItem:"tw-group"},floatingOptions:{whileElementsMounted(...l){return w.autoUpdate(...l,{animationFrame:!0})}}}),VC0={options:{trigger:"@",createMentionNode:e=>({value:e.text,key:e.key,category:e.data.category})}},DC0={root:[`
63
63
  font-size: inherit;
64
64
  box-shadow: none;
65
65
  display: inline-block;