Skip to content

Commit e3b34ff

Browse files
committed
Refactor route state field to support multiple states
1 parent f9c4202 commit e3b34ff

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

scripts/apidocgen/postprocess/main.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -169,12 +169,12 @@ func writeDocs(sections [][]byte) error {
169169

170170
// Update manifest.json
171171
type route struct {
172-
Title string `json:"title,omitempty"`
173-
Description string `json:"description,omitempty"`
174-
Path string `json:"path,omitempty"`
175-
IconPath string `json:"icon_path,omitempty"`
176-
State string `json:"state,omitempty"`
177-
Children []route `json:"children,omitempty"`
172+
Title string `json:"title,omitempty"`
173+
Description string `json:"description,omitempty"`
174+
Path string `json:"path,omitempty"`
175+
IconPath string `json:"icon_path,omitempty"`
176+
State []string `json:"state,omitempty"`
177+
Children []route `json:"children,omitempty"`
178178
}
179179

180180
type manifest struct {

scripts/clidocgen/main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ type route struct {
1818
Description string `json:"description,omitempty"`
1919
Path string `json:"path,omitempty"`
2020
IconPath string `json:"icon_path,omitempty"`
21-
State []string `json:"state,omitempty"` // Changed to []string to support an array of states
21+
State []string `json:"state,omitempty"`
2222
Children []route `json:"children,omitempty"`
2323
}
2424

0 commit comments

Comments
 (0)