Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import classNames from 'classnames';
// eslint-disable-next-line import/no-unresolved
import logo from '../../assets/logo.svg?raw';

Comment thread
char0n marked this conversation as resolved.
const SplashScreen = ({ isOpen = true, getComponent }) => {
const SplashScreen = ({ isOpen = true, version, getComponent }) => {
const { PACKAGE_VERSION } = buildInfo; // eslint-disable-line no-undef
const SplashScreenSpinner = getComponent('SplashScreenSpinner');
const [isHidden, setHidden] = useState(!isOpen);
Expand All @@ -24,7 +24,7 @@ const SplashScreen = ({ isOpen = true, getComponent }) => {
>
<figure className="swagger-editor__splash-screen-figure">
<img width="100%" src={logo} alt="Swagger Editor" />
<figcaption>{PACKAGE_VERSION}</figcaption>
<figcaption>{version ?? PACKAGE_VERSION}</figcaption>
<SplashScreenSpinner />
</figure>
</div>
Expand All @@ -33,6 +33,7 @@ const SplashScreen = ({ isOpen = true, getComponent }) => {

SplashScreen.propTypes = {
isOpen: PropTypes.bool,
version: PropTypes.string,
getComponent: PropTypes.func.isRequired,
};

Expand Down