mirror of
https://github.com/Redocly/redoc.git
synced 2025-07-02 02:03:04 +03:00
fix: discriminator dropdown showing incorrect field if sorted
This commit is contained in:
parent
3924d3c1be
commit
bcf39dc2cf
|
@ -38,14 +38,11 @@ export class DiscriminatorDropdown extends React.Component<{
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const activeItem = options[parent.activeOneOf];
|
||||||
this.sortOptions(options, enumValues);
|
this.sortOptions(options, enumValues);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<StyledDropdown
|
<StyledDropdown value={activeItem} options={options} onChange={this.changeActiveChild} />
|
||||||
value={options[parent.activeOneOf]}
|
|
||||||
options={options}
|
|
||||||
onChange={this.changeActiveChild}
|
|
||||||
/>
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user