Skip to content

[DOCS] Implement collapsible sections for nested objects in Elasticsearch APIs #54667

@lcawl

Description

@lcawl

We have created a stylesheet to make it easier to delineate nested objects in the API reference pages: elastic/docs#1786

We have already implemented it in machine learning APIs like https://www.elastic.co/guide/en/elasticsearch/reference/master/get-dfanalytics-stats.html and https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-put-job.html

It involves setting [role="child_attributes"] on the section that contains nested objects, then putting the objects in collabsible sections, which default to open for search purposes.

The following APIs contain nested objects and would likely benefit from this layout too:

P.S. The child_attributes stylesheet is not set in stone either. If there are better colours or padding, input is welcome on https://github.com/elastic/docs/blob/master/resources/web/style/child_attributes.pcss

Metadata

Metadata

Assignees

Labels

>docsGeneral docs changes

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions