LearnNewsExamplesServices
Frontmatter
id8234
title[Neural Link] Implement toJSON in layout.Flexbox
stateClosed
labels
enhancementai
assigneestobiu
createdAtDec 31, 2025, 4:18 PM
updatedAtDec 31, 2025, 4:20 PM
githubUrlhttps://github.com/neomjs/neo/issues/8234
authortobiu
commentsCount1
parentIssue8200
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtDec 31, 2025, 4:20 PM

[Neural Link] Implement toJSON in layout.Flexbox

Closed v11.18.0 enhancementai
tobiu
tobiu commented on Dec 31, 2025, 4:18 PM

Implement the toJSON method in src/layout/Flexbox.mjs to support the Neural Link serialization protocol.

It should return an object containing:

  • Properties from super.toJSON()
  • align
  • direction
  • gap
  • pack
  • prefix
  • wrap

Note: Neo.layout.HBox and Neo.layout.VBox extend Flexbox, so they will automatically inherit this serialization.

tobiu added the enhancement label on Dec 31, 2025, 4:18 PM
tobiu added the ai label on Dec 31, 2025, 4:18 PM
tobiu added parent issue #8200 on Dec 31, 2025, 4:18 PM
tobiu assigned to @tobiu on Dec 31, 2025, 4:19 PM
tobiu referenced in commit de7c530 - "feat(layout): Implement toJSON in Neo.layout.Flexbox for Neural Link serialization (#8234)" on Dec 31, 2025, 4:19 PM
tobiu
tobiu Dec 31, 2025, 4:19 PM

Input from Gemini:

✦ I have implemented the toJSON method in src/layout/Flexbox.mjs. It returns:

{
    ...super.toJSON(),
    align    : this.align,
    direction: this.direction,
    gap      : this.gap,
    pack     : this.pack,
    prefix   : this.prefix,
    wrap     : this.wrap
}

This serialization is also inherited by Neo.layout.HBox and Neo.layout.VBox.

tobiu closed this issue on Dec 31, 2025, 4:20 PM
tobiu referenced in commit 938ace2 - "docs(issue): Close ticket #8234" on Dec 31, 2025, 4:22 PM