@vectoriox/iox-builder 1.4.23 → 1.4.25

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": "1.4.23",
3
+ "version": "1.4.25",
4
4
  "peerDependencies": {
5
5
  "@angular/common": ">=20.0.0",
6
6
  "@angular/core": ">=20.0.0",
@@ -97,7 +97,19 @@ interface IoxInteraction {
97
97
  id: string;
98
98
  trigger: InteractionTrigger;
99
99
  actions: InteractionAction[];
100
+ /**
101
+ * Optional second set of actions for click-toggle behaviour.
102
+ * When set, the first click runs `actions` and the second click runs
103
+ * `reverseActions`, alternating on every subsequent click.
104
+ * Only meaningful for trigger === 'click'.
105
+ */
106
+ reverseActions?: InteractionAction[];
100
107
  }
108
+ /**
109
+ * Maps each action type to its logical inverse for auto-populating toggle
110
+ * reverse actions. Types without a natural inverse are omitted.
111
+ */
112
+ declare const INVERSE_ACTION: Partial<Record<InteractionActionType, InteractionActionType>>;
101
113
  declare const TRIGGER_OPTIONS: {
102
114
  value: InteractionTrigger;
103
115
  label: string;
@@ -587,6 +599,11 @@ declare class InteractionEngineService {
587
599
  private attached;
588
600
  /** Elements that have had pre-state applied (hidden by attach). */
589
601
  private preStatedElements;
602
+ /**
603
+ * Toggle state for click interactions with reverseActions.
604
+ * false = next click runs actions (primary); true = next click runs reverseActions.
605
+ */
606
+ private toggleStates;
590
607
  /**
591
608
  * Pre-states queued for elements that weren't registered yet when the owner
592
609
  * node's attach() ran. Keyed by target node ID. Consumed when the target
@@ -1398,6 +1415,11 @@ declare class InteractionsPanelComponent implements OnInit, OnDestroy {
1398
1415
  removeInteraction(id: string): void;
1399
1416
  addAction(interaction: IoxInteraction): void;
1400
1417
  removeAction(interaction: IoxInteraction, index: number): void;
1418
+ hasToggle(interaction: IoxInteraction): boolean;
1419
+ enableToggle(interaction: IoxInteraction): void;
1420
+ disableToggle(interaction: IoxInteraction): void;
1421
+ addReverseAction(interaction: IoxInteraction): void;
1422
+ removeReverseAction(interaction: IoxInteraction, index: number): void;
1401
1423
  static ɵfac: i0.ɵɵFactoryDeclaration<InteractionsPanelComponent, never>;
1402
1424
  static ɵcmp: i0.ɵɵComponentDeclaration<InteractionsPanelComponent, "app-interactions-panel", never, { "node": { "alias": "node"; "required": false; }; }, {}, never, never, false, never>;
1403
1425
  }
@@ -1475,5 +1497,5 @@ declare class TextBlockComponentConfig extends ComponentConfig {
1475
1497
  constructor();
1476
1498
  }
1477
1499
 
1478
- export { ACTION_TYPE_OPTIONS, BuilderButtonBlockComponent, BuilderButtonComponentConfig, BuilderComponent, BuilderContainerComponent, BuilderContainerComponentConfig, BuilderDividerComponentConfig, BuilderHeadingComponentConfig, BuilderIconComponentConfig, BuilderImageComponentConfig, BuilderLinkComponentConfig, BuilderLinkedContainerComponent, BuilderLinkedContainerConfig, BuilderMode, BuilderRepeaterComponent, BuilderSpacerComponentConfig, ButtonBlockComponentConfig, CardComponentConfig, ComponentConfig, ComponentRegistryService, DEVICE_OPTIONS, DataSourceRegistryService, DeviceMode, DragEngineService, EASING_OPTIONS, GroupStyleConfig, INTERACTION_STATES, IOX_CONTENT_SERVICE, IOX_FONT_MANAGER, InteractionEngineService, InteractionsPanelComponent, IoxBuilderModule, IoxDraggableDirective, IoxDropzoneDirective, LayerTreeComponent, NodeAction, OverlayComponent, OverlayService, PanelChildComponent, PanelComponent, PanelEventService, PanelEventTypes, PanelTypes, PresetRegistryService, ROUTE_ANIMATION_OPTIONS, RenderDirective, RepeaterComponentConfig, SCREEN_WIDTH_OPTIONS, STRUCTURAL_STATES, SUPPORTED_STATES, SectionComponent, SectionComponentConfig, StyleCategory, StyleRegistryService, TraitConfig as StyleTraitConfig, TRIGGER_OPTIONS, TextBlockComponentConfig, ToolbarAction, ToolbarComponent, TraitConfig, TraitInputType, UNITS_ALL, UNITS_DEG, UNITS_FIXED, UNITS_NO_VW, VIRTUAL_TRAIT_KEYS, ViewportService, ZOOM_OPTIONS, buildFullStyleTraits, buildPresetStyleTraits, composeVirtualTraits, defaultPageSettings, generateNodeId, resolveTraitControllerType, resolveTraitOptions };
1500
+ export { ACTION_TYPE_OPTIONS, BuilderButtonBlockComponent, BuilderButtonComponentConfig, BuilderComponent, BuilderContainerComponent, BuilderContainerComponentConfig, BuilderDividerComponentConfig, BuilderHeadingComponentConfig, BuilderIconComponentConfig, BuilderImageComponentConfig, BuilderLinkComponentConfig, BuilderLinkedContainerComponent, BuilderLinkedContainerConfig, BuilderMode, BuilderRepeaterComponent, BuilderSpacerComponentConfig, ButtonBlockComponentConfig, CardComponentConfig, ComponentConfig, ComponentRegistryService, DEVICE_OPTIONS, DataSourceRegistryService, DeviceMode, DragEngineService, EASING_OPTIONS, GroupStyleConfig, INTERACTION_STATES, INVERSE_ACTION, IOX_CONTENT_SERVICE, IOX_FONT_MANAGER, InteractionEngineService, InteractionsPanelComponent, IoxBuilderModule, IoxDraggableDirective, IoxDropzoneDirective, LayerTreeComponent, NodeAction, OverlayComponent, OverlayService, PanelChildComponent, PanelComponent, PanelEventService, PanelEventTypes, PanelTypes, PresetRegistryService, ROUTE_ANIMATION_OPTIONS, RenderDirective, RepeaterComponentConfig, SCREEN_WIDTH_OPTIONS, STRUCTURAL_STATES, SUPPORTED_STATES, SectionComponent, SectionComponentConfig, StyleCategory, StyleRegistryService, TraitConfig as StyleTraitConfig, TRIGGER_OPTIONS, TextBlockComponentConfig, ToolbarAction, ToolbarComponent, TraitConfig, TraitInputType, UNITS_ALL, UNITS_DEG, UNITS_FIXED, UNITS_NO_VW, VIRTUAL_TRAIT_KEYS, ViewportService, ZOOM_OPTIONS, buildFullStyleTraits, buildPresetStyleTraits, composeVirtualTraits, defaultPageSettings, generateNodeId, resolveTraitControllerType, resolveTraitOptions };
1479
1501
  export type { ComponentNode, ComponentTrait, DeviceOption, DragPayload, DsFilterByQueryParam, DsFilterByRouteParam, ElementState, InteractionAction, InteractionActionType, InteractionTrigger, IoxBinding, IoxContentService, IoxDataSource, IoxDropEvent, IoxFontManager, IoxInteraction, NodeRef, OverlayBoxModel, OverlayBoxSpacing, OverlayEntry, PageRouteAnimationSettings, PageScrollSettings, PageSettings, PageStyleSettings, PanelEvent, QuadSizeSegment, RouteAnimationPreset, ScreenWidthOption, StylePreset, StyleTrait, StyleTraitGroup, TraitOptionMap, TraitSelectOption, TraitShowCondition, ViewportState, ZoomOption };