@vectoriox/iox-ui 5.62.0 → 5.62.1
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
|
@@ -400,7 +400,8 @@ export function expandWireField(wire: unknown): ContentFieldPlan | unknown {
|
|
|
400
400
|
|
|
401
401
|
export function expandWireContentType(wire: unknown, options: WireOptions = {}): ContentTypePlan | unknown {
|
|
402
402
|
if (!isPlainObject(wire)) return wire;
|
|
403
|
-
const
|
|
403
|
+
const written: PlainObject = options.children === false ? { fields: [], ...wire } : wire;
|
|
404
|
+
const { roles, fields, seed, ...rest } = written;
|
|
404
405
|
const out: PlainObject = { ...rest, roles: listToMap(roles, 'role', 'field'), fields: each(fields, expandWireField) };
|
|
405
406
|
if (!isPlainObject(seed)) return seed === undefined ? out : { ...out, seed };
|
|
406
407
|
const { values, ...fixed } = seed;
|
|
@@ -436,7 +437,8 @@ export function expandWireSection(wire: unknown): PageSectionPlan | unknown {
|
|
|
436
437
|
|
|
437
438
|
export function expandWirePage(wire: unknown, options: WireOptions = {}): PagePlan | unknown {
|
|
438
439
|
if (!isPlainObject(wire)) return wire;
|
|
439
|
-
const
|
|
440
|
+
const written: PlainObject = options.children === false ? { sections: [], ...wire } : wire;
|
|
441
|
+
const { archetype, need, template, routeSource, seo, sections, ...rest } = written;
|
|
440
442
|
const words = isPlainObject(seo) ? { ...optional('title', seo['title']), ...optional('description', seo['description']) } : seo;
|
|
441
443
|
return {
|
|
442
444
|
...rest,
|