@forgeax/app-shell 0.62.0 → 0.64.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 +23 -1
- package/dist/react.js +75 -0
- package/package.json +1 -1
package/dist/react.d.ts
CHANGED
|
@@ -324,6 +324,28 @@ interface ReplaceableObservationSetLifecycle<Item> {
|
|
|
324
324
|
/** Own a replaceable set of subscriptions without owning item or event policy. */
|
|
325
325
|
declare function createReplaceableObservationSetLifecycle<Item, Observation>(options: ReplaceableObservationSetOptions<Item, Observation>): ReplaceableObservationSetLifecycle<Item>;
|
|
326
326
|
|
|
327
|
+
interface PanelMembershipObservationSubscription {
|
|
328
|
+
dispose(): void;
|
|
329
|
+
}
|
|
330
|
+
interface PanelMembershipObservationOptions<AddEvent = unknown, RemoveEvent = unknown> {
|
|
331
|
+
readonly subscribeAdd: (listener: (event: AddEvent) => void) => PanelMembershipObservationSubscription;
|
|
332
|
+
readonly subscribeRemove: (listener: (event: RemoveEvent) => void) => PanelMembershipObservationSubscription;
|
|
333
|
+
readonly onAdd: (event: AddEvent) => void;
|
|
334
|
+
readonly onRemove: (event: RemoveEvent) => void;
|
|
335
|
+
}
|
|
336
|
+
/** Observe panel membership changes without owning panel or layout policy. */
|
|
337
|
+
declare function installPanelMembershipObservation<AddEvent, RemoveEvent>(options: PanelMembershipObservationOptions<AddEvent, RemoveEvent>): () => void;
|
|
338
|
+
|
|
339
|
+
interface ActivePanelObservationSubscription {
|
|
340
|
+
dispose(): void;
|
|
341
|
+
}
|
|
342
|
+
interface ActivePanelObservationOptions<ChangeEvent = unknown> {
|
|
343
|
+
readonly subscribe: (listener: (event: ChangeEvent) => void) => ActivePanelObservationSubscription;
|
|
344
|
+
readonly onChange: (event: ChangeEvent) => void;
|
|
345
|
+
}
|
|
346
|
+
/** Observe active-panel changes without owning panel selection or reconciliation policy. */
|
|
347
|
+
declare function installActivePanelObservation<ChangeEvent>(options: ActivePanelObservationOptions<ChangeEvent>): () => void;
|
|
348
|
+
|
|
327
349
|
type PanelContentPadding = 'none' | 'sm' | 'md';
|
|
328
350
|
type PanelContentScroll = 'none' | 'auto';
|
|
329
351
|
type PanelContentTone = 'default' | 'surface' | 'tool';
|
|
@@ -465,4 +487,4 @@ interface ShellSlotProps extends HTMLAttributes<HTMLElement> {
|
|
|
465
487
|
/** Structural shell marker that preserves the caller's semantic element. */
|
|
466
488
|
declare function ShellSlot({ as, name, ...props }: ShellSlotProps): ReactElement;
|
|
467
489
|
|
|
468
|
-
export { type AnchoredResizeDirection, AnchoredResizeHandle, type AnchoredResizeHandleProps, type AnchoredResizeSession, type BoundedFrameRetryLifecycleOptions, type CaptureInteractionEventTarget, type CaptureInteractionObservationOptions, 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, type ReplaceableObservationSetLifecycle, type ReplaceableObservationSetOptions, type ReplaceableObservationSubscription, 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, createReplaceableObservationSetLifecycle, hashSlotHue, installBoundedFrameRetryLifecycle, installCaptureInteractionObservation, installCustomEventObservation, installDragPresenceLifecycle, installOutsideDismissLifecycle, installPointerDragSession, installPointerReorderSession, installThresholdPointerDragSession, installViewportResizeObservation, isDismissExemptInteractionTarget, isSlotDebugEnabled, useDockLayoutControlBinding, useLiveTabPlacement, useLiveTabTitle, useLocalSize, usePersistentSizeStore, useTabCloseInteractions, useTabPinnedState };
|
|
490
|
+
export { type ActivePanelObservationOptions, type ActivePanelObservationSubscription, type AnchoredResizeDirection, AnchoredResizeHandle, type AnchoredResizeHandleProps, type AnchoredResizeSession, type BoundedFrameRetryLifecycleOptions, type CaptureInteractionEventTarget, type CaptureInteractionObservationOptions, 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, type PanelMembershipObservationOptions, type PanelMembershipObservationSubscription, PanelSurface, type PanelSurfaceProps, type PersistentSizeStorage, type PersistentSizeStore, type PersistentSizeStoreOptions, type PersistentSizeUpdate, type PointerDragFinishReason, type PointerDragSessionOptions, type PointerReorderFinishReason, type PointerReorderSession, type PointerReorderSessionOptions, type ReplaceableObservationSetLifecycle, type ReplaceableObservationSetOptions, type ReplaceableObservationSubscription, 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, createReplaceableObservationSetLifecycle, hashSlotHue, installActivePanelObservation, installBoundedFrameRetryLifecycle, installCaptureInteractionObservation, installCustomEventObservation, installDragPresenceLifecycle, installOutsideDismissLifecycle, installPanelMembershipObservation, installPointerDragSession, installPointerReorderSession, installThresholdPointerDragSession, installViewportResizeObservation, isDismissExemptInteractionTarget, isSlotDebugEnabled, useDockLayoutControlBinding, useLiveTabPlacement, useLiveTabTitle, useLocalSize, usePersistentSizeStore, useTabCloseInteractions, useTabPinnedState };
|
package/dist/react.js
CHANGED
|
@@ -2127,6 +2127,79 @@ function createReplaceableObservationSetLifecycle(options) {
|
|
|
2127
2127
|
};
|
|
2128
2128
|
}
|
|
2129
2129
|
|
|
2130
|
+
// src/panel-membership-observation.ts
|
|
2131
|
+
function installPanelMembershipObservation(options) {
|
|
2132
|
+
let live = true;
|
|
2133
|
+
let addSubscription;
|
|
2134
|
+
let removeSubscription;
|
|
2135
|
+
const onAdd = (event) => {
|
|
2136
|
+
if (!live) return;
|
|
2137
|
+
try {
|
|
2138
|
+
options.onAdd(event);
|
|
2139
|
+
} catch {
|
|
2140
|
+
}
|
|
2141
|
+
};
|
|
2142
|
+
const onRemove = (event) => {
|
|
2143
|
+
if (!live) return;
|
|
2144
|
+
try {
|
|
2145
|
+
options.onRemove(event);
|
|
2146
|
+
} catch {
|
|
2147
|
+
}
|
|
2148
|
+
};
|
|
2149
|
+
const disposeOne = (subscription) => {
|
|
2150
|
+
if (!subscription) return;
|
|
2151
|
+
try {
|
|
2152
|
+
subscription.dispose();
|
|
2153
|
+
} catch {
|
|
2154
|
+
}
|
|
2155
|
+
};
|
|
2156
|
+
try {
|
|
2157
|
+
addSubscription = options.subscribeAdd(onAdd);
|
|
2158
|
+
removeSubscription = options.subscribeRemove(onRemove);
|
|
2159
|
+
} catch {
|
|
2160
|
+
live = false;
|
|
2161
|
+
disposeOne(removeSubscription);
|
|
2162
|
+
disposeOne(addSubscription);
|
|
2163
|
+
}
|
|
2164
|
+
return () => {
|
|
2165
|
+
if (!live) return;
|
|
2166
|
+
live = false;
|
|
2167
|
+
disposeOne(removeSubscription);
|
|
2168
|
+
disposeOne(addSubscription);
|
|
2169
|
+
};
|
|
2170
|
+
}
|
|
2171
|
+
|
|
2172
|
+
// src/active-panel-observation.ts
|
|
2173
|
+
function installActivePanelObservation(options) {
|
|
2174
|
+
let live = true;
|
|
2175
|
+
let subscription;
|
|
2176
|
+
const onChange = (event) => {
|
|
2177
|
+
if (!live) return;
|
|
2178
|
+
try {
|
|
2179
|
+
options.onChange(event);
|
|
2180
|
+
} catch {
|
|
2181
|
+
}
|
|
2182
|
+
};
|
|
2183
|
+
const disposeSubscription = () => {
|
|
2184
|
+
if (!subscription) return;
|
|
2185
|
+
try {
|
|
2186
|
+
subscription.dispose();
|
|
2187
|
+
} catch {
|
|
2188
|
+
}
|
|
2189
|
+
};
|
|
2190
|
+
try {
|
|
2191
|
+
subscription = options.subscribe(onChange);
|
|
2192
|
+
} catch {
|
|
2193
|
+
live = false;
|
|
2194
|
+
disposeSubscription();
|
|
2195
|
+
}
|
|
2196
|
+
return () => {
|
|
2197
|
+
if (!live) return;
|
|
2198
|
+
live = false;
|
|
2199
|
+
disposeSubscription();
|
|
2200
|
+
};
|
|
2201
|
+
}
|
|
2202
|
+
|
|
2130
2203
|
// src/panel.tsx
|
|
2131
2204
|
import { jsx as jsx5, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
2132
2205
|
function PanelEmptyState({
|
|
@@ -2502,11 +2575,13 @@ export {
|
|
|
2502
2575
|
createPersistentSizeStore,
|
|
2503
2576
|
createReplaceableObservationSetLifecycle,
|
|
2504
2577
|
hashSlotHue,
|
|
2578
|
+
installActivePanelObservation,
|
|
2505
2579
|
installBoundedFrameRetryLifecycle,
|
|
2506
2580
|
installCaptureInteractionObservation,
|
|
2507
2581
|
installCustomEventObservation,
|
|
2508
2582
|
installDragPresenceLifecycle,
|
|
2509
2583
|
installOutsideDismissLifecycle,
|
|
2584
|
+
installPanelMembershipObservation,
|
|
2510
2585
|
installPointerDragSession,
|
|
2511
2586
|
installPointerReorderSession,
|
|
2512
2587
|
installThresholdPointerDragSession,
|