Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add sprintif
  • Loading branch information
Kateryna Kodonenko
Kateryna Kodonenko committed Jun 11, 2024
commit af02dbb33cd562e5aa90cddf51fc6864f72e0ace
2 changes: 1 addition & 1 deletion src/about-menu/about-menu.html
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
<div>
<img src="./studio-app-icon.png" alt="Studio App Icon" width="64" height="64">
<p class="studio-name" id="studio-by-wpcom">Studio by WordPress.com</p>
<p class="version" id="version-text">Version</p>
<p class="version"><span id="version-text">Version x.y.z</span></p>
<p class="links">
<a href="https://github.com/Automattic/studio" target="_blank">GitHub</a>

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did not add translation for GitHub since it is a proper name. Happy to add it if it is considered necessary.

<span class="separator">&middot;</span>
Expand Down
4 changes: 2 additions & 2 deletions src/about-menu/open-about-menu.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { BrowserWindow, app, shell } from 'electron';
import path from 'path';
import * as Sentry from '@sentry/electron/renderer';
import { __ } from '@wordpress/i18n';
import { sprintf, __ } from '@wordpress/i18n';
import { ABOUT_WINDOW_HEIGHT, ABOUT_WINDOW_WIDTH } from '../constants';

let aboutWindow: BrowserWindow | null = null;
Expand Down Expand Up @@ -39,7 +39,7 @@ export function openAboutWindow() {

aboutWindow.webContents.on( 'dom-ready', () => {
if ( aboutWindow ) {
const versionText = `${ __( 'Version' ) } ${ packageJson }`;
const versionText = sprintf( __( 'Version %s' ), packageJson );

// Inject version into the about window's HTML
aboutWindow.webContents
Expand Down