@forgeax/app-shell 0.59.0 → 0.60.0
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/react.d.ts +13 -1
- package/dist/react.js +39 -0
- package/package.json +1 -1
package/dist/react.d.ts
CHANGED
|
@@ -286,6 +286,18 @@ interface ViewportResizeObservationOptions {
|
|
|
286
286
|
/** Observe viewport resize without owning the caller's geometry policy. */
|
|
287
287
|
declare function installViewportResizeObservation(options: ViewportResizeObservationOptions): () => void;
|
|
288
288
|
|
|
289
|
+
interface CustomEventObservationTarget {
|
|
290
|
+
addEventListener(type: string, listener: EventListener): void;
|
|
291
|
+
removeEventListener(type: string, listener: EventListener): void;
|
|
292
|
+
}
|
|
293
|
+
interface CustomEventObservationOptions {
|
|
294
|
+
readonly eventType: string;
|
|
295
|
+
readonly target?: CustomEventObservationTarget;
|
|
296
|
+
readonly onEvent: (event: Event) => void;
|
|
297
|
+
}
|
|
298
|
+
/** Observe a caller-owned custom event without owning its payload or command policy. */
|
|
299
|
+
declare function installCustomEventObservation(options: CustomEventObservationOptions): () => void;
|
|
300
|
+
|
|
289
301
|
type PanelContentPadding = 'none' | 'sm' | 'md';
|
|
290
302
|
type PanelContentScroll = 'none' | 'auto';
|
|
291
303
|
type PanelContentTone = 'default' | 'surface' | 'tool';
|
|
@@ -427,4 +439,4 @@ interface ShellSlotProps extends HTMLAttributes<HTMLElement> {
|
|
|
427
439
|
/** Structural shell marker that preserves the caller's semantic element. */
|
|
428
440
|
declare function ShellSlot({ as, name, ...props }: ShellSlotProps): ReactElement;
|
|
429
441
|
|
|
430
|
-
export { type AnchoredResizeDirection, AnchoredResizeHandle, type AnchoredResizeHandleProps, type AnchoredResizeSession, type BoundedFrameRetryLifecycleOptions, type CoalescedFrameTaskLifecycle, type CoalescedFrameTaskLifecycleOptions, DetachedPanelBoundary, type DetachedPanelBoundaryProps, DetachedSurfaceFrame, type DetachedSurfaceFrameProps, DetachedSurfaceStatus, type DetachedSurfaceStatusProps, type DetachedSurfaceStatusTone, type DockLayoutControlBinding, type DockLayoutControlBindingOptions, DockLayoutMenu, type DockLayoutMenuPanel, type DockLayoutMenuProps, DockTabAction, type DockTabActionProps, DockTabFrame, type DockTabFrameProps, DockTabIcon, type DockTabIconProps, DockTabStatusSummary, type DockTabStatusSummaryItem, type DockTabStatusSummaryProps, type DockTabStatusTone, DockTabTitle, type DockTabTitleProps, type DragPresenceEventTarget, type DragPresenceLifecycleOptions, FloatingMenu, type FloatingMenuAnchor, type FloatingMenuPoint, type FloatingMenuProps, type LiveTabPlacement, type LiveTabPlacementSource, type LiveTabTitleSource, OWNED_INTERACTION_SURFACE_SELECTOR, type OutsideDismissEventTarget, type OutsideDismissLifecycleOptions, type OutsideDismissReason, type PanelContentPadding, type PanelContentPolicy, type PanelContentScroll, type PanelContentTone, PanelEmptyState, type PanelEmptyStateProps, PanelSurface, type PanelSurfaceProps, type PersistentSizeStorage, type PersistentSizeStore, type PersistentSizeStoreOptions, type PersistentSizeUpdate, type PointerDragFinishReason, type PointerDragSessionOptions, type PointerReorderFinishReason, type PointerReorderSession, type PointerReorderSessionOptions, ResizeHandle, type ResizeHandleProps, ShellSlot, type ShellSlotElement, type ShellSlotProps, SlotDebugOverlay, SurfacePlaceholder, type SurfacePlaceholderProps, SurfaceRegion, type SurfaceRegionProps, type TabCloseInteractions, type TabCloseInteractionsOptions, type TabPinnedStateSource, type ThresholdPointerDragFinishReason, type ThresholdPointerDragSession, type ThresholdPointerDragSessionOptions, type ViewportResizeEventTarget, type ViewportResizeObservationOptions, applyAnchoredResizeDelta, beginAnchoredResize, createCoalescedFrameTaskLifecycle, createPersistentSizeStore, hashSlotHue, installBoundedFrameRetryLifecycle, installDragPresenceLifecycle, installOutsideDismissLifecycle, installPointerDragSession, installPointerReorderSession, installThresholdPointerDragSession, installViewportResizeObservation, isDismissExemptInteractionTarget, isSlotDebugEnabled, useDockLayoutControlBinding, useLiveTabPlacement, useLiveTabTitle, useLocalSize, usePersistentSizeStore, useTabCloseInteractions, useTabPinnedState };
|
|
442
|
+
export { type AnchoredResizeDirection, AnchoredResizeHandle, type AnchoredResizeHandleProps, type AnchoredResizeSession, type BoundedFrameRetryLifecycleOptions, type CoalescedFrameTaskLifecycle, type CoalescedFrameTaskLifecycleOptions, type CustomEventObservationOptions, type CustomEventObservationTarget, DetachedPanelBoundary, type DetachedPanelBoundaryProps, DetachedSurfaceFrame, type DetachedSurfaceFrameProps, DetachedSurfaceStatus, type DetachedSurfaceStatusProps, type DetachedSurfaceStatusTone, type DockLayoutControlBinding, type DockLayoutControlBindingOptions, DockLayoutMenu, type DockLayoutMenuPanel, type DockLayoutMenuProps, DockTabAction, type DockTabActionProps, DockTabFrame, type DockTabFrameProps, DockTabIcon, type DockTabIconProps, DockTabStatusSummary, type DockTabStatusSummaryItem, type DockTabStatusSummaryProps, type DockTabStatusTone, DockTabTitle, type DockTabTitleProps, type DragPresenceEventTarget, type DragPresenceLifecycleOptions, FloatingMenu, type FloatingMenuAnchor, type FloatingMenuPoint, type FloatingMenuProps, type LiveTabPlacement, type LiveTabPlacementSource, type LiveTabTitleSource, OWNED_INTERACTION_SURFACE_SELECTOR, type OutsideDismissEventTarget, type OutsideDismissLifecycleOptions, type OutsideDismissReason, type PanelContentPadding, type PanelContentPolicy, type PanelContentScroll, type PanelContentTone, PanelEmptyState, type PanelEmptyStateProps, PanelSurface, type PanelSurfaceProps, type PersistentSizeStorage, type PersistentSizeStore, type PersistentSizeStoreOptions, type PersistentSizeUpdate, type PointerDragFinishReason, type PointerDragSessionOptions, type PointerReorderFinishReason, type PointerReorderSession, type PointerReorderSessionOptions, ResizeHandle, type ResizeHandleProps, ShellSlot, type ShellSlotElement, type ShellSlotProps, SlotDebugOverlay, SurfacePlaceholder, type SurfacePlaceholderProps, SurfaceRegion, type SurfaceRegionProps, type TabCloseInteractions, type TabCloseInteractionsOptions, type TabPinnedStateSource, type ThresholdPointerDragFinishReason, type ThresholdPointerDragSession, type ThresholdPointerDragSessionOptions, type ViewportResizeEventTarget, type ViewportResizeObservationOptions, applyAnchoredResizeDelta, beginAnchoredResize, createCoalescedFrameTaskLifecycle, createPersistentSizeStore, hashSlotHue, installBoundedFrameRetryLifecycle, installCustomEventObservation, installDragPresenceLifecycle, installOutsideDismissLifecycle, installPointerDragSession, installPointerReorderSession, installThresholdPointerDragSession, installViewportResizeObservation, isDismissExemptInteractionTarget, isSlotDebugEnabled, useDockLayoutControlBinding, useLiveTabPlacement, useLiveTabTitle, useLocalSize, usePersistentSizeStore, useTabCloseInteractions, useTabPinnedState };
|
package/dist/react.js
CHANGED
|
@@ -1970,6 +1970,44 @@ function installViewportResizeObservation(options) {
|
|
|
1970
1970
|
};
|
|
1971
1971
|
}
|
|
1972
1972
|
|
|
1973
|
+
// src/custom-event-observation.ts
|
|
1974
|
+
function installCustomEventObservation(options) {
|
|
1975
|
+
const target = options.target ?? (typeof window === "undefined" ? void 0 : window);
|
|
1976
|
+
if (!target) return () => {
|
|
1977
|
+
};
|
|
1978
|
+
let disposed = false;
|
|
1979
|
+
let registered = false;
|
|
1980
|
+
const listener = (event) => {
|
|
1981
|
+
if (disposed) return;
|
|
1982
|
+
try {
|
|
1983
|
+
options.onEvent(event);
|
|
1984
|
+
} catch {
|
|
1985
|
+
}
|
|
1986
|
+
};
|
|
1987
|
+
try {
|
|
1988
|
+
registered = true;
|
|
1989
|
+
target.addEventListener(options.eventType, listener);
|
|
1990
|
+
} catch {
|
|
1991
|
+
disposed = true;
|
|
1992
|
+
if (registered) {
|
|
1993
|
+
try {
|
|
1994
|
+
target.removeEventListener(options.eventType, listener);
|
|
1995
|
+
} catch {
|
|
1996
|
+
}
|
|
1997
|
+
}
|
|
1998
|
+
}
|
|
1999
|
+
return () => {
|
|
2000
|
+
if (disposed) return;
|
|
2001
|
+
disposed = true;
|
|
2002
|
+
if (registered) {
|
|
2003
|
+
try {
|
|
2004
|
+
target.removeEventListener(options.eventType, listener);
|
|
2005
|
+
} catch {
|
|
2006
|
+
}
|
|
2007
|
+
}
|
|
2008
|
+
};
|
|
2009
|
+
}
|
|
2010
|
+
|
|
1973
2011
|
// src/panel.tsx
|
|
1974
2012
|
import { jsx as jsx5, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
1975
2013
|
function PanelEmptyState({
|
|
@@ -2345,6 +2383,7 @@ export {
|
|
|
2345
2383
|
createPersistentSizeStore,
|
|
2346
2384
|
hashSlotHue,
|
|
2347
2385
|
installBoundedFrameRetryLifecycle,
|
|
2386
|
+
installCustomEventObservation,
|
|
2348
2387
|
installDragPresenceLifecycle,
|
|
2349
2388
|
installOutsideDismissLifecycle,
|
|
2350
2389
|
installPointerDragSession,
|