@vectoriox/iox-ui 4.36.0 → 4.38.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/fesm2022/vectoriox-iox-ui.mjs +162 -14
- package/fesm2022/vectoriox-iox-ui.mjs.map +1 -1
- package/index.d.ts +71 -2
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -2032,6 +2032,17 @@ interface SeoDoc {
|
|
|
2032
2032
|
structuredData?: unknown;
|
|
2033
2033
|
sitemap?: SeoSitemap;
|
|
2034
2034
|
}
|
|
2035
|
+
/**
|
|
2036
|
+
* A binding on an SEO field. Structurally the resolvable part of an `IoxBinding` — `source` picks an
|
|
2037
|
+
* entry in the page's resolved data (`$current` on a template page), `path` walks into it, `pipes`
|
|
2038
|
+
* are the render-time transforms. Typed loosely because the pipe catalog lives in the main
|
|
2039
|
+
* `@vectoriox/iox-ui` entry point, which this framework-free one must not import.
|
|
2040
|
+
*/
|
|
2041
|
+
interface SeoBinding {
|
|
2042
|
+
source: string;
|
|
2043
|
+
path?: string;
|
|
2044
|
+
pipes?: readonly unknown[];
|
|
2045
|
+
}
|
|
2035
2046
|
|
|
2036
2047
|
/**
|
|
2037
2048
|
* Turn a page's STORED SEO document into the resolved one a crawler should see.
|
|
@@ -2076,6 +2087,64 @@ declare function resolveSeo(seo: unknown, ctx?: SeoResolveContext): SeoDoc;
|
|
|
2076
2087
|
*/
|
|
2077
2088
|
declare function deriveSeoFromContent(tree: readonly unknown[] | null | undefined, resolvedData?: Record<string, unknown> | null): SeoDerivedContent;
|
|
2078
2089
|
|
|
2090
|
+
/**
|
|
2091
|
+
* The authoring-side view of the SEO ladder: which rung won for each field, and what to show.
|
|
2092
|
+
*
|
|
2093
|
+
* The panel must never re-derive this. The chip an author reads ("AUTO" / "BOUND" / "MANUAL") has to
|
|
2094
|
+
* mean exactly what the renderer will do, and the only way to guarantee that is to compute it from
|
|
2095
|
+
* the same `resolveSeo` the renderer uses. See iox-ai-guidance `architecture/cms/seo-plan.md`.
|
|
2096
|
+
*/
|
|
2097
|
+
type SeoFieldSource =
|
|
2098
|
+
/** The author typed it. */
|
|
2099
|
+
'manual'
|
|
2100
|
+
/** A binding supplies it — the value is only known at render time. */
|
|
2101
|
+
| 'bound'
|
|
2102
|
+
/** Derived from the page's own content or URL. */
|
|
2103
|
+
| 'auto'
|
|
2104
|
+
/** Nothing supplies it: automatic derivation is off, or there was nothing to derive. */
|
|
2105
|
+
| 'empty';
|
|
2106
|
+
interface SeoFieldState {
|
|
2107
|
+
/** Dotted path into the document, e.g. `title`, `og.image`. */
|
|
2108
|
+
field: string;
|
|
2109
|
+
/** What the author typed, when they did. Drives the input's value. */
|
|
2110
|
+
override: string;
|
|
2111
|
+
/** The binding, when one is set. */
|
|
2112
|
+
binding?: SeoBinding;
|
|
2113
|
+
/** The value as far as it can be known here — empty for a bound field. */
|
|
2114
|
+
resolved: string;
|
|
2115
|
+
/** Which rung won. */
|
|
2116
|
+
source: SeoFieldSource;
|
|
2117
|
+
/** Recommended length, where one applies — for the character counter. */
|
|
2118
|
+
maxLength?: number;
|
|
2119
|
+
}
|
|
2120
|
+
/**
|
|
2121
|
+
* Describe every bindable field for the authoring panel.
|
|
2122
|
+
*
|
|
2123
|
+
* ⚠️ `resolved` is deliberately EMPTY for a bound field on the builder side. The canvas has no
|
|
2124
|
+
* page-level resolved data — each component fetches its own — so a bound value genuinely is not
|
|
2125
|
+
* knowable here. Showing the binding expression and saying so is honest; inventing a preview from
|
|
2126
|
+
* design-time props is how a placeholder ends up looking like real content.
|
|
2127
|
+
*/
|
|
2128
|
+
declare function describeSeoFields(seo: unknown, ctx?: SeoResolveContext): SeoFieldState[];
|
|
2129
|
+
/** Set a field's typed value. An empty string CLEARS the override so the lower rungs take over. */
|
|
2130
|
+
declare function setSeoOverride(seo: unknown, field: string, value: string): Record<string, unknown>;
|
|
2131
|
+
/** Attach or replace a field's binding. `undefined` removes it. */
|
|
2132
|
+
declare function setSeoBinding(seo: unknown, field: string, binding: SeoBinding | undefined): Record<string, unknown>;
|
|
2133
|
+
/** Turn the automatic rung on or off for a field. Off leaves the field genuinely empty. */
|
|
2134
|
+
declare function setSeoAuto(seo: unknown, field: string, enabled: boolean): Record<string, unknown>;
|
|
2135
|
+
/**
|
|
2136
|
+
* Set a field that is NOT part of the ladder — `robots`, `twitter.card`, `structuredData`,
|
|
2137
|
+
* `sitemap.*`. These are pick-lists, switches and blobs: they have no override/binding/auto, so they
|
|
2138
|
+
* are stored as plain values, exactly as the normalizer reads them.
|
|
2139
|
+
*
|
|
2140
|
+
* `undefined`, `null` and `''` remove the field, so an unset pick-list leaves no husk behind.
|
|
2141
|
+
*/
|
|
2142
|
+
declare function setSeoValue(seo: unknown, field: string, value: unknown): Record<string, unknown>;
|
|
2143
|
+
/** Read any field's plain stored value — the counterpart of `setSeoValue`. */
|
|
2144
|
+
declare function getSeoValue(seo: unknown, field: string): unknown;
|
|
2145
|
+
/** Drop everything an author set on a field — back to the automatic rung. */
|
|
2146
|
+
declare function resetSeoField(seo: unknown, field: string): Record<string, unknown>;
|
|
2147
|
+
|
|
2079
2148
|
/**
|
|
2080
2149
|
* Element context state — shared types.
|
|
2081
2150
|
*
|
|
@@ -2576,5 +2645,5 @@ declare class GalleryLoop {
|
|
|
2576
2645
|
private emit;
|
|
2577
2646
|
}
|
|
2578
2647
|
|
|
2579
|
-
export { AOSService, AnalyticsService, BREAKPOINTS, Breakpoint, BreakpointQueryKind, BuilderButtonComponent, BuilderDividerComponent, BuilderHeadingComponent, BuilderIconComponent, BuilderImageComponent, BuilderLinkComponent, BuilderSpacerComponent, ButtonBlockComponent, CMSClientInfraModule, CONTEXT_ACTION_TYPES, CardComponent, ClientGalleryComponent, ClientListComponent, ClientListItemComponent, ClientRepeaterComponent, ClientSliderContainerComponent, ClientSliderSlideComponent, ComponentInstanceRegistryService, ConsentService, ContainerComponent, ContentService, ContextStore, DEFAULT_GALLERY_SCHEDULER, DEFAULT_PAGE_TRANSITION, DEFAULT_PAGE_TRANSITION_DURATION, DEFAULT_PAGE_TRANSITION_EASING, DEFAULT_PAGE_TRANSITION_PERSPECTIVE, DEFAULT_PHOSPHOR_WEIGHT, DEFAULT_WIDTH_BY_TYPE, DeclarationContext, ENVIRONMENT, FormRenderState, FormRuntimeService, GALLERY_EFFECTS, GALLERY_EFFECT_DESCRIPTORS, GalleryLoop, IOX_BUILDER_EVENTS, IOX_FORM_MESSAGES, IOX_FORM_NAVIGATOR, IOX_FORM_TRANSPORT, IS_PREVIEW, IoxAnimateContainer, IoxAosDirective, IoxAosModule, IoxBuilderComponentsModule, IoxComponentRegistryService, IoxFieldComponent, IoxFormComponent, IoxFormErrorComponent, IoxFormSuccessComponent, IoxPageComponent, IoxPageModule, IoxSubmitButtonComponent, IoxUiModule, LinkedContainerComponent, PAGE_TRANSITION_CATEGORIES, PAGE_TRANSITION_PRESETS, PIPE_DESCRIPTORS, PIPE_REGISTRY, PageScrollProvider, PrivacyModalComponent, PrivacyModalService, PrivacyModelEvent, RESERVED_ALIAS_PREFIX, SUPPRESSED_STYLE_PROPS_BY_TYPE, SWIPER_RESPONSIVE_TRAITS, SectionComponent, TRANSITION_FEELS, TextBlockComponent, VIRTUAL_TRAIT_GROUPS, VIRTUAL_TRAIT_KEYS, ViewPositionDirective, ViewPositionModule, WebSettingsService, activeActions, applyBindingPipes, applyFeel, breakpointDef, breakpointForWidth, breakpointQueryFor, buildDataSourceFilter, buildRelatedFilter, buildSwiperBreakpoints, buildTargetedStateSelector, buildTransitionTimeline, cascadeChain, clearInputOverride, clearOverride, collectContextSlotKeys, collectReferencedAliases, compileDeclarations, composeVirtualTraits, computeRelative, contextActionEffect, contextSlotKeys, countOverrides, dataSourcePlanToRequest, declaredInputNames, defaultMessageResolver, deriveSeoFromContent, effectiveTransitionId, excludeSelf, feelFor, getByPath, initialSlotValues, isActionEnabled, isContextAction, isInputOverriddenAt, isOverriddenAt, isReservedAlias, isValidSlotKey, legacyEnterToTransition, matchRouteParams, mediaQueryFor, mergeSwiperBreakpoints, nearestCommonAncestorId, nodeCssId, nodeUsesContext, normalizeCollectionResult, normalizeGalleryImage, normalizeIconClass, parentBreakpoint, parseUrlList, planDataSource, planResponsiveRules, referencedDataSources, referencedDataSourcesDeep, renderDefaultDeclarations, resolveBoundValue, resolveContextValue, resolveDerivedInto, resolveGalleryEffect, resolveGalleryUrls, resolveInputChain, resolveInputs, resolvePageTransition, resolvePath, resolveRelativeInto, resolveRepeaterItems, resolveSeo, resolveSiblings, resolveSingleItemId, resolveStateStyles, resolveStyleProps, resolveValueChain, rewriteViewportUnits, safeSetInput, setInputOverride, setOverride, stateNamesIn, stripSuppressedProps, styleKeyToKebab, variableAliases, variableItemsFrom, withContextSlots, wrapInBreakpointQuery, wrapInMediaQuery };
|
|
2580
|
-
export type { BoundValueSpec, BreakpointDef, BuildRelatedFilterOptions, ContextActionEffect, ContextActionLike, ContextItemRef, ContextSlotDefault, ContextValueSpec, ContextWriteScope, DataSourceDomain, DataSourceEndpoints, DataSourceMode, DataSourcePlan, DataSourceQueryFilter, DataSourceRequest, DataSourceRequestSpec, DataSourceRouteFilter, DataSourceSpec, FormMessageResolver, GalleryBoundSource, GalleryDurations, GalleryEffect, GalleryEffectDescriptor, GalleryImage, GalleryLoopOptions, GalleryLoopScheduler, GalleryLoopState, GallerySlideState, IBuilderEventEmitter, InputMap, IoxContextSlot, IoxPipe, OverrideBreakpoint, PageTransitionCategory, PageTransitionCategoryMeta, PageTransitionOptions, PageTransitionPreset, PipeArgSpec, PipeContext, PipeDescriptor, RelativeInputs, RelativeSourceKind, RelativeSourceSpec, ResolveSiblingsOptions, ResolvedPageTransition, ResponsiveLayer, ResponsiveOverrides, ResponsiveRuleSet, RouteContext, SeoDerivedContent, SeoResolveContext, SetContextParams, SiblingsResult, StateStyleMap, StyleMap, StyleTreeNode, SwiperBreakpointMap, ToggleableAction, TransitionFeel, TransitionPhase, TransitionTimelineInput, ValueSource, VirtualTraitGroup };
|
|
2648
|
+
export { AOSService, AnalyticsService, BREAKPOINTS, Breakpoint, BreakpointQueryKind, BuilderButtonComponent, BuilderDividerComponent, BuilderHeadingComponent, BuilderIconComponent, BuilderImageComponent, BuilderLinkComponent, BuilderSpacerComponent, ButtonBlockComponent, CMSClientInfraModule, CONTEXT_ACTION_TYPES, CardComponent, ClientGalleryComponent, ClientListComponent, ClientListItemComponent, ClientRepeaterComponent, ClientSliderContainerComponent, ClientSliderSlideComponent, ComponentInstanceRegistryService, ConsentService, ContainerComponent, ContentService, ContextStore, DEFAULT_GALLERY_SCHEDULER, DEFAULT_PAGE_TRANSITION, DEFAULT_PAGE_TRANSITION_DURATION, DEFAULT_PAGE_TRANSITION_EASING, DEFAULT_PAGE_TRANSITION_PERSPECTIVE, DEFAULT_PHOSPHOR_WEIGHT, DEFAULT_WIDTH_BY_TYPE, DeclarationContext, ENVIRONMENT, FormRenderState, FormRuntimeService, GALLERY_EFFECTS, GALLERY_EFFECT_DESCRIPTORS, GalleryLoop, IOX_BUILDER_EVENTS, IOX_FORM_MESSAGES, IOX_FORM_NAVIGATOR, IOX_FORM_TRANSPORT, IS_PREVIEW, IoxAnimateContainer, IoxAosDirective, IoxAosModule, IoxBuilderComponentsModule, IoxComponentRegistryService, IoxFieldComponent, IoxFormComponent, IoxFormErrorComponent, IoxFormSuccessComponent, IoxPageComponent, IoxPageModule, IoxSubmitButtonComponent, IoxUiModule, LinkedContainerComponent, PAGE_TRANSITION_CATEGORIES, PAGE_TRANSITION_PRESETS, PIPE_DESCRIPTORS, PIPE_REGISTRY, PageScrollProvider, PrivacyModalComponent, PrivacyModalService, PrivacyModelEvent, RESERVED_ALIAS_PREFIX, SUPPRESSED_STYLE_PROPS_BY_TYPE, SWIPER_RESPONSIVE_TRAITS, SectionComponent, TRANSITION_FEELS, TextBlockComponent, VIRTUAL_TRAIT_GROUPS, VIRTUAL_TRAIT_KEYS, ViewPositionDirective, ViewPositionModule, WebSettingsService, activeActions, applyBindingPipes, applyFeel, breakpointDef, breakpointForWidth, breakpointQueryFor, buildDataSourceFilter, buildRelatedFilter, buildSwiperBreakpoints, buildTargetedStateSelector, buildTransitionTimeline, cascadeChain, clearInputOverride, clearOverride, collectContextSlotKeys, collectReferencedAliases, compileDeclarations, composeVirtualTraits, computeRelative, contextActionEffect, contextSlotKeys, countOverrides, dataSourcePlanToRequest, declaredInputNames, defaultMessageResolver, deriveSeoFromContent, describeSeoFields, effectiveTransitionId, excludeSelf, feelFor, getByPath, getSeoValue, initialSlotValues, isActionEnabled, isContextAction, isInputOverriddenAt, isOverriddenAt, isReservedAlias, isValidSlotKey, legacyEnterToTransition, matchRouteParams, mediaQueryFor, mergeSwiperBreakpoints, nearestCommonAncestorId, nodeCssId, nodeUsesContext, normalizeCollectionResult, normalizeGalleryImage, normalizeIconClass, parentBreakpoint, parseUrlList, planDataSource, planResponsiveRules, referencedDataSources, referencedDataSourcesDeep, renderDefaultDeclarations, resetSeoField, resolveBoundValue, resolveContextValue, resolveDerivedInto, resolveGalleryEffect, resolveGalleryUrls, resolveInputChain, resolveInputs, resolvePageTransition, resolvePath, resolveRelativeInto, resolveRepeaterItems, resolveSeo, resolveSiblings, resolveSingleItemId, resolveStateStyles, resolveStyleProps, resolveValueChain, rewriteViewportUnits, safeSetInput, setInputOverride, setOverride, setSeoAuto, setSeoBinding, setSeoOverride, setSeoValue, stateNamesIn, stripSuppressedProps, styleKeyToKebab, variableAliases, variableItemsFrom, withContextSlots, wrapInBreakpointQuery, wrapInMediaQuery };
|
|
2649
|
+
export type { BoundValueSpec, BreakpointDef, BuildRelatedFilterOptions, ContextActionEffect, ContextActionLike, ContextItemRef, ContextSlotDefault, ContextValueSpec, ContextWriteScope, DataSourceDomain, DataSourceEndpoints, DataSourceMode, DataSourcePlan, DataSourceQueryFilter, DataSourceRequest, DataSourceRequestSpec, DataSourceRouteFilter, DataSourceSpec, FormMessageResolver, GalleryBoundSource, GalleryDurations, GalleryEffect, GalleryEffectDescriptor, GalleryImage, GalleryLoopOptions, GalleryLoopScheduler, GalleryLoopState, GallerySlideState, IBuilderEventEmitter, InputMap, IoxContextSlot, IoxPipe, OverrideBreakpoint, PageTransitionCategory, PageTransitionCategoryMeta, PageTransitionOptions, PageTransitionPreset, PipeArgSpec, PipeContext, PipeDescriptor, RelativeInputs, RelativeSourceKind, RelativeSourceSpec, ResolveSiblingsOptions, ResolvedPageTransition, ResponsiveLayer, ResponsiveOverrides, ResponsiveRuleSet, RouteContext, SeoDerivedContent, SeoFieldSource, SeoFieldState, SeoResolveContext, SetContextParams, SiblingsResult, StateStyleMap, StyleMap, StyleTreeNode, SwiperBreakpointMap, ToggleableAction, TransitionFeel, TransitionPhase, TransitionTimelineInput, ValueSource, VirtualTraitGroup };
|