@octaviaflow/core 3.1.0-beta.64 → 3.1.0-beta.65

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.
package/dist/index.js CHANGED
@@ -254,6 +254,28 @@ function ActionRow({
254
254
  e.dataTransfer.setData(dragMimeType, JSON.stringify(payload));
255
255
  e.dataTransfer.setData("text/plain", item.label);
256
256
  e.dataTransfer.effectAllowed = "copy";
257
+ if (typeof document !== "undefined") {
258
+ const ghost = document.createElement("div");
259
+ ghost.textContent = item.label;
260
+ ghost.setAttribute("aria-hidden", "true");
261
+ const s = ghost.style;
262
+ s.position = "fixed";
263
+ s.top = "-1000px";
264
+ s.left = "-1000px";
265
+ s.padding = "6px 12px";
266
+ s.borderRadius = "6px";
267
+ s.background = "var(--ods-surface-canvas, #ffffff)";
268
+ s.color = "var(--ods-text-primary, #111827)";
269
+ s.border = "1px solid var(--ods-border-strong, #9ca3af)";
270
+ s.font = "500 13px var(--ods-font-family-sans, sans-serif)";
271
+ s.boxShadow = "0 4px 12px rgba(0,0,0,0.18)";
272
+ s.whiteSpace = "nowrap";
273
+ s.pointerEvents = "none";
274
+ s.zIndex = "9999";
275
+ document.body.appendChild(ghost);
276
+ e.dataTransfer.setDragImage(ghost, 12, 16);
277
+ window.setTimeout(() => ghost.remove(), 0);
278
+ }
257
279
  onDragStart?.(item);
258
280
  },
259
281
  [item, dragMimeType, onDragStart]