@vectoriox/iox-builder 2.5.0 → 2.6.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vectoriox/iox-builder",
3
- "version": "2.5.0",
3
+ "version": "2.6.0",
4
4
  "peerDependencies": {
5
5
  "@angular/common": ">=20.0.0",
6
6
  "@angular/core": ">=20.0.0",
@@ -522,7 +522,8 @@ declare enum ToolbarAction {
522
522
  PasteInteractionPreset = "paste-interaction-preset",
523
523
  Copy = "copy",
524
524
  Paste = "paste",
525
- AddSlide = "add-slide"
525
+ AddSlide = "add-slide",
526
+ Wrap = "wrap"
526
527
  }
527
528
  declare enum NodeAction {
528
529
  Delete = "delete",
@@ -1376,6 +1377,7 @@ declare class BuilderComponent implements OnInit, AfterViewInit, OnChanges, OnDe
1376
1377
  entry: OverlayEntry;
1377
1378
  position?: 'before' | 'after';
1378
1379
  interaction?: IoxInteraction;
1380
+ wrapType?: string;
1379
1381
  }): void;
1380
1382
  confirmSaveBlock(): void;
1381
1383
  cancelSaveBlock(): void;
@@ -1553,7 +1555,16 @@ declare class OverlayComponent implements OnInit, OnDestroy {
1553
1555
  entry: OverlayEntry;
1554
1556
  position?: "before" | "after";
1555
1557
  interaction?: IoxInteraction;
1558
+ wrapType?: string;
1556
1559
  }>;
1560
+ /** Element types the selected node can be wrapped in (Wrap-in submenu). Phase 1: layout containers. */
1561
+ readonly wrapTargets: {
1562
+ type: string;
1563
+ label: string;
1564
+ icon: string;
1565
+ }[];
1566
+ /** Whether the Wrap-in flyout submenu is open (hover-driven). */
1567
+ wrapSubmenuOpen: boolean;
1557
1568
  hoverEntry: OverlayEntry | null;
1558
1569
  selectEntry: OverlayEntry | null;
1559
1570
  hiOutlineStyle: Record<string, string>;
@@ -1585,6 +1596,9 @@ declare class OverlayComponent implements OnInit, OnDestroy {
1585
1596
  onSelectParent(event: MouseEvent): void;
1586
1597
  onDuplicate(event: MouseEvent): void;
1587
1598
  onDelete(event: MouseEvent): void;
1599
+ onWrap(event: MouseEvent, wrapType: string): void;
1600
+ /** Slider slides must stay direct children of the slider container — never wrap them. */
1601
+ get canWrap(): boolean;
1588
1602
  onPlay(event: MouseEvent): void;
1589
1603
  onSaveAsBlock(event: MouseEvent): void;
1590
1604
  onToggleMore(event: MouseEvent): void;
@@ -2204,6 +2218,38 @@ declare class IoxBuilderModule {
2204
2218
  static ɵinj: i0.ɵɵInjectorDeclaration<IoxBuilderModule>;
2205
2219
  }
2206
2220
 
2221
+ /**
2222
+ * Locate a node within a forest (array of root nodes + their descendants) by
2223
+ * reference identity. Returns the parent array holding the node and its index,
2224
+ * or `null` if the node is not present.
2225
+ *
2226
+ * Reference-based to match the rest of the builder tree operations, which pass
2227
+ * the live `ComponentNode` object around (see `findNodeInTree`).
2228
+ */
2229
+ declare function findNodeLocation(roots: ComponentNode[], target: ComponentNode): {
2230
+ parent: ComponentNode[];
2231
+ index: number;
2232
+ } | null;
2233
+ /**
2234
+ * Wrap `target` inside `wrapper`, in place, within the forest it already lives in.
2235
+ *
2236
+ * The wrapper replaces the target at its original position and takes the target
2237
+ * as its only child. **Context is preserved** — the operation never moves the
2238
+ * node between the page and global trees; the caller passes the forest the node
2239
+ * lives in (page layout OR global elements), and the surgery stays inside it.
2240
+ *
2241
+ * Global flags (`isGlobal`/`globalPosition`) are carried ONLY by the top-level
2242
+ * node of the global forest. When wrapping such a node, those flags transfer to
2243
+ * the wrapper — which becomes the new top-level global node — and are cleared on
2244
+ * the now-inner node, so the element keeps rendering in its global slot. Wrapping
2245
+ * anything else (a page node, or a child nested inside a global element) leaves
2246
+ * all global flags untouched.
2247
+ *
2248
+ * @returns the wrapper on success, or `null` if the target was not found (in
2249
+ * which case nothing is mutated).
2250
+ */
2251
+ declare function wrapNode(roots: ComponentNode[], target: ComponentNode, wrapper: ComponentNode): ComponentNode | null;
2252
+
2207
2253
  interface HistoryEntry {
2208
2254
  layout: ComponentNode[];
2209
2255
  timestamp: number;
@@ -2319,5 +2365,5 @@ declare class TextBlockComponentConfig extends ComponentConfig {
2319
2365
  constructor();
2320
2366
  }
2321
2367
 
2322
- export { ACTION_TYPE_OPTIONS, BackgroundGroupStyleConfig, BorderGroupStyleConfig, BuilderButtonBlockComponent, BuilderButtonComponentConfig, BuilderClipboardService, BuilderComponent, BuilderContainerComponent, BuilderContainerComponentConfig, BuilderDataSourceService, BuilderDividerComponentConfig, BuilderHeadingComponentConfig, BuilderHistoryService, BuilderIconComponentConfig, BuilderImageComponentConfig, BuilderLinkComponentConfig, BuilderLinkedContainerComponent, BuilderLinkedContainerConfig, BuilderListComponentConfig, BuilderListItemComponentConfig, BuilderMode, BuilderRepeaterComponent, BuilderSpacerComponentConfig, ButtonBlockComponentConfig, CardComponentConfig, ChildLayoutGroupStyleConfig, ComponentConfig, ComponentRegistryService, DEVICE_OPTIONS, DataSourceRegistryService, DataSourceType, DeviceMode, DimensionsGroupStyleConfig, DragEngineService, EASING_OPTIONS, EffectsGroupStyleConfig, GroupStyleConfig, INTERACTION_STATES, INVERSE_ACTION, IOX_DATA_SOURCE_ENDPOINTS, IOX_FONT_MANAGER, InteractionEngineService, InteractionPresetRegistryService, InteractionsPanelComponent, IoxBuilderModule, IoxDraggableDirective, IoxDropzoneDirective, LayerTreeComponent, LayoutGroupStyleConfig, ListGroupStyleConfig, NodeAction, OverlayComponent, OverlayService, PanelChildComponent, PanelComponent, PanelEventService, PanelEventTypes, PanelTypes, PositionGroupStyleConfig, PresetRegistryService, RELATIONAL_STATES, RELATIONAL_STATE_BASE, ROUTE_ANIMATION_OPTIONS, RenderDirective, RepeaterComponentConfig, SCREEN_WIDTH_OPTIONS, STRUCTURAL_STATES, SUPPORTED_STATES, SectionComponent, SectionComponentConfig, SizeGroupStyleConfig, SliderContainerComponent, SliderContainerConfig, SliderSlideComponent, SliderSlideConfig, SpacingGroupStyleConfig, StyleCategory, StyleRegistryService, TraitConfig as StyleTraitConfig, SymbolRegistryService, TRIGGER_OPTIONS, TextBlockComponentConfig, ToolbarAction, ToolbarComponent, TraitConfig, TraitInputType, TypographyGroupStyleConfig, UNITS_ALL, UNITS_DEG, UNITS_FIXED, UNITS_NO_VW, ViewportService, ZOOM_OPTIONS, arrayItemSchemaFields, arraySchemaFields, buildFullStyleTraits, buildPresetStyleTraits, defaultPageSettings, flattenSchemaFields, generateNodeId, resolveTraitControllerType, resolveTraitOptions };
2368
+ export { ACTION_TYPE_OPTIONS, BackgroundGroupStyleConfig, BorderGroupStyleConfig, BuilderButtonBlockComponent, BuilderButtonComponentConfig, BuilderClipboardService, BuilderComponent, BuilderContainerComponent, BuilderContainerComponentConfig, BuilderDataSourceService, BuilderDividerComponentConfig, BuilderHeadingComponentConfig, BuilderHistoryService, BuilderIconComponentConfig, BuilderImageComponentConfig, BuilderLinkComponentConfig, BuilderLinkedContainerComponent, BuilderLinkedContainerConfig, BuilderListComponentConfig, BuilderListItemComponentConfig, BuilderMode, BuilderRepeaterComponent, BuilderSpacerComponentConfig, ButtonBlockComponentConfig, CardComponentConfig, ChildLayoutGroupStyleConfig, ComponentConfig, ComponentRegistryService, DEVICE_OPTIONS, DataSourceRegistryService, DataSourceType, DeviceMode, DimensionsGroupStyleConfig, DragEngineService, EASING_OPTIONS, EffectsGroupStyleConfig, GroupStyleConfig, INTERACTION_STATES, INVERSE_ACTION, IOX_DATA_SOURCE_ENDPOINTS, IOX_FONT_MANAGER, InteractionEngineService, InteractionPresetRegistryService, InteractionsPanelComponent, IoxBuilderModule, IoxDraggableDirective, IoxDropzoneDirective, LayerTreeComponent, LayoutGroupStyleConfig, ListGroupStyleConfig, NodeAction, OverlayComponent, OverlayService, PanelChildComponent, PanelComponent, PanelEventService, PanelEventTypes, PanelTypes, PositionGroupStyleConfig, PresetRegistryService, RELATIONAL_STATES, RELATIONAL_STATE_BASE, ROUTE_ANIMATION_OPTIONS, RenderDirective, RepeaterComponentConfig, SCREEN_WIDTH_OPTIONS, STRUCTURAL_STATES, SUPPORTED_STATES, SectionComponent, SectionComponentConfig, SizeGroupStyleConfig, SliderContainerComponent, SliderContainerConfig, SliderSlideComponent, SliderSlideConfig, SpacingGroupStyleConfig, StyleCategory, StyleRegistryService, TraitConfig as StyleTraitConfig, SymbolRegistryService, TRIGGER_OPTIONS, TextBlockComponentConfig, ToolbarAction, ToolbarComponent, TraitConfig, TraitInputType, TypographyGroupStyleConfig, UNITS_ALL, UNITS_DEG, UNITS_FIXED, UNITS_NO_VW, ViewportService, ZOOM_OPTIONS, arrayItemSchemaFields, arraySchemaFields, buildFullStyleTraits, buildPresetStyleTraits, defaultPageSettings, findNodeLocation, flattenSchemaFields, generateNodeId, resolveTraitControllerType, resolveTraitOptions, wrapNode };
2323
2369
  export type { BuilderClipboard, ComponentEventDef, ComponentMethodDef, ComponentNode, ComponentTrait, DeviceOption, DragPayload, DsFilterByQueryParam, DsFilterByRouteParam, ElementState, HistoryEntry, InteractionAction, InteractionActionType, InteractionPreset, InteractionTrigger, IoxBinding, IoxDataSource, IoxDropEvent, IoxFontManager, IoxInteraction, IoxSymbol, NodeRef, OverlayBoxModel, OverlayBoxSpacing, OverlayEntry, PageRouteAnimationSettings, PageScrollSettings, PageSettings, PageStyleSettings, PanelEvent, QuadSizeSegment, RouteAnimationPreset, ScreenWidthOption, StylePreset, StyleTrait, StyleTraitGroup, TraitOptionMap, TraitSelectOption, TraitShowCondition, ViewportState, ZoomOption };