Skip to content

🎨 [Frontend] Enh: Wording and .po file #7418

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 30 commits into from
Mar 25, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
5015351
print services
odeimaiz Mar 24, 2025
f96f85b
Merge branch 'master' into enh/services-pricing-plans
odeimaiz Mar 24, 2025
a4f1818
getService reject
odeimaiz Mar 24, 2025
78a82fd
[skip ci] ensure that even if one request fails, the rest continue ex…
odeimaiz Mar 24, 2025
db8add2
show error message
odeimaiz Mar 24, 2025
7091384
[skip ci] minor
odeimaiz Mar 24, 2025
bd1c9ad
minor
odeimaiz Mar 24, 2025
dfb614a
minor fix
odeimaiz Mar 24, 2025
942c795
minor
odeimaiz Mar 24, 2025
ef6d314
added po file
odeimaiz Mar 24, 2025
4876f32
qx_translate_extract
odeimaiz Mar 24, 2025
1c41a32
Merge branch 'master' into feature/locales
odeimaiz Mar 25, 2025
d3a6b6d
uncomment
odeimaiz Mar 25, 2025
65959f0
more doc
odeimaiz Mar 25, 2025
be7f307
Merge branch 'master' into feature/locales
odeimaiz Mar 25, 2025
8694aef
Merge branch 'feature/locales' of github.com:odeimaiz/osparc-simcore …
odeimaiz Mar 25, 2025
f4bb829
minor
odeimaiz Mar 25, 2025
eda0c27
doc
odeimaiz Mar 25, 2025
6c5bffa
Merge branch 'master' into feature/locales
odeimaiz Mar 25, 2025
69d5b12
rewording I
odeimaiz Mar 25, 2025
3b593a8
Merge branch 'feature/locales' of github.com:odeimaiz/osparc-simcore …
odeimaiz Mar 25, 2025
af384c6
rewording II
odeimaiz Mar 25, 2025
1f7cf0f
rewording III
odeimaiz Mar 25, 2025
67f1de3
rewording IIII
odeimaiz Mar 25, 2025
a723a3c
rewording last
odeimaiz Mar 25, 2025
ef38234
Merge branch 'master' into feature/locales
odeimaiz Mar 25, 2025
3132e72
minor
odeimaiz Mar 25, 2025
2cfc3b9
minor refactor
odeimaiz Mar 25, 2025
7ce69a3
removeTasks
odeimaiz Mar 25, 2025
b58e986
Merge branch 'feature/locales' of github.com:odeimaiz/osparc-simcore …
odeimaiz Mar 25, 2025
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
3 changes: 0 additions & 3 deletions services/static-webserver/client/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,3 @@ source/resource/iconfont/material
# generator outputs
/api/
/test/

# translations for the moment ignored
*.po
11 changes: 11 additions & 0 deletions services/static-webserver/client/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,17 @@ serve: compile ## serves site compiled in image in 127.0.0.1:8080
docker run --rm -p 8080:8080 $(docker_image) $(qx_serve) --target=build


# qx translate --------------------------

define qx_translate_extract =
qx compile --update-po-files
endef

.PHONY: translate-extract
translate-extract: translate-extract ## the generated .po files goes to source/translation https://qooxdoo.org/documentation/v7.8/#/development/howto/internationalization?id=translation
# qx compile --update-po-files
$(docker_compose) run $(if $(detached),--detach --name=$(detached),--rm) qooxdoo-kit $(qx_translate_extract)


# misc --------------------------
.PHONY: shell
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ qx.Class.define("osparc.Application", {
const webSocket = osparc.wrapper.WebSocket.getInstance();
webSocket.addListener("connect", () => osparc.WatchDog.getInstance().setOnline(true));
webSocket.addListener("disconnect", () => osparc.WatchDog.getInstance().setOnline(false));
webSocket.addListener("logout", () => this.logout(qx.locale.Manager.tr("You were logged out")));
webSocket.addListener("logout", () => this.logout(qx.locale.Manager.tr("You have been logged out")));
// alert the users that they are about to navigate away
// from osparc. unfortunately it is not possible
// to provide our own message here
Expand Down Expand Up @@ -371,7 +371,7 @@ qx.Class.define("osparc.Application", {
__checkNewRelease: function() {
if (osparc.NewRelease.firstTimeISeeThisFrontend()) {
const newRelease = new osparc.NewRelease();
const title = this.tr("New Release");
const title = this.tr("New Version Released");
const win = osparc.ui.window.Window.popUpInWindow(newRelease, title, 350, 135).set({
clickAwayClose: false,
resizable: false,
Expand Down Expand Up @@ -563,7 +563,7 @@ qx.Class.define("osparc.Application", {
if (forcedReason) {
osparc.FlashMessenger.logAs(forcedReason, "WARNING", 0);
} else {
osparc.FlashMessenger.logAs(this.tr("You are logged out"), "INFO");
osparc.FlashMessenger.logAs(this.tr("You have been logged out"), "INFO");
}
this.__closeAllAndToLoginPage();
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ qx.Class.define("osparc.CookieExpirationTracker", {
// /FLASH MESSAGE //

__logoutUser: function() {
const reason = qx.locale.Manager.tr("Session expired");
const reason = qx.locale.Manager.tr("Your session has expired");
qx.core.Init.getApplication().logout(reason);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ qx.Class.define("osparc.MaintenanceTracker", {
end: null,
reason: null
});
const reason = qx.locale.Manager.tr("We are under maintenance. Please check back later");
const reason = qx.locale.Manager.tr("The service is under maintenance. Please check back later");
qx.core.Init.getApplication().logout(reason);
},

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ qx.Class.define("osparc.TooSmallDialog", {
extend: osparc.ui.window.SingletonWindow,

construct: function() {
this.base(arguments, "too-small-logout", this.tr("Window too small"));
this.base(arguments, "too-small-logout", this.tr("Window size too small"));

this.set({
layout: new qx.ui.layout.VBox(10),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ qx.Class.define("osparc.auth.ui.Login2FAValidationCodeView", {
alignY: "middle"
}));
const resendCodeDesc = new qx.ui.basic.Label().set({
value: this.tr("Didn't receive the code? Resend code")
value: this.tr("Didn't receive the code? Click to resend")
});
resendLayout.add(resendCodeDesc);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@ qx.Class.define("osparc.auth.ui.RequestAccount", {
};
osparc.data.Resources.fetch("auth", "postRequestAccount", params)
.then(() => {
const msg = this.tr("The request is being processed, you will hear from us in the coming hours");
const msg = this.tr("Your request is being processed. You will hear from us soon");
osparc.FlashMessenger.logAs(msg, "INFO");
this.fireDataEvent("done");
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ qx.Class.define("osparc.auth.ui.VerifyPhoneNumberView", {
this.add(verificationInfoTitle);

const verificationInfoDesc = new qx.ui.basic.Label().set({
value: this.tr("We will send you a text message to your mobile phone to authenticate you each time you log in."),
value: this.tr("A text message will be sent to your mobile phone for authentication each time you log in."),
rich: true,
wrap: true
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2141,16 +2141,18 @@ qx.Class.define("osparc.dashboard.StudyBrowser", {
if (msg) {
osparc.FlashMessenger.logAs(msg, msgLevel);
}
osparc.store.PollTasks.getInstance().removeTask(task);
osparc.task.TasksContainer.getInstance().removeTaskUI(taskUI);
this._resourcesContainer.removeNonResourceCard(duplicatingStudyCard);
};

task.addListener("taskAborted", () => {
const msg = this.tr("Duplication cancelled");
finished(msg, "INFO");
finished(msg, "WARNING");
});
task.addListener("resultReceived", e => {
finished();
const msg = this.tr("Duplication completed");
finished(msg, "INFO");
const duplicatedStudyData = e.getData();
this._updateStudyData(duplicatedStudyData);
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -346,18 +346,40 @@ qx.Class.define("osparc.dashboard.TemplateBrowser", {
// MENU //

// TASKS //
__tasksToCards: function() {
const tasks = osparc.store.PollTasks.getInstance().getPublishTemplateTasks();
tasks.forEach(task => {
const studyName = "";
this.taskToTemplateReceived(task, studyName);
});
},

taskToTemplateReceived: function(task, studyName) {
const toTemplateTaskUI = new osparc.task.ToTemplate(studyName);
toTemplateTaskUI.setTask(task);

osparc.task.TasksContainer.getInstance().addTaskUI(toTemplateTaskUI);

const cardTitle = this.tr("Publishing ") + studyName;
const toTemplateCard = this._addTaskCard(task, cardTitle, osparc.task.ToTemplate.ICON);
if (toTemplateCard) {
this.__attachToTemplateEventHandler(task, toTemplateTaskUI, toTemplateCard);
}
},

__attachToTemplateEventHandler: function(task, taskUI, toTemplateCard) {
const finished = (msg, msgLevel) => {
if (msg) {
osparc.FlashMessenger.logAs(msg, msgLevel);
}
osparc.store.PollTasks.getInstance().removeTask(task);
osparc.task.TasksContainer.getInstance().removeTaskUI(taskUI);
this._resourcesContainer.removeNonResourceCard(toTemplateCard);
};

task.addListener("taskAborted", () => {
const msg = this.tr("Study to Template cancelled");
finished(msg, "INFO");
finished(msg, "WARNING");
});
task.addListener("updateReceived", e => {
const updateData = e.getData();
Expand All @@ -372,7 +394,8 @@ qx.Class.define("osparc.dashboard.TemplateBrowser", {
}
}, this);
task.addListener("resultReceived", e => {
finished();
const msg = this.tr("Template created");
finished(msg, "INFO");
this.reloadResources();
});
task.addListener("pollingError", e => {
Expand All @@ -381,27 +404,6 @@ qx.Class.define("osparc.dashboard.TemplateBrowser", {
finished(msg, "ERROR");
});
},

__tasksToCards: function() {
const tasks = osparc.store.PollTasks.getInstance().getPublishTemplateTasks();
tasks.forEach(task => {
const studyName = "";
this.taskToTemplateReceived(task, studyName);
});
},

taskToTemplateReceived: function(task, studyName) {
const toTemplateTaskUI = new osparc.task.ToTemplate(studyName);
toTemplateTaskUI.setTask(task);

osparc.task.TasksContainer.getInstance().addTaskUI(toTemplateTaskUI);

const cardTitle = this.tr("Publishing ") + studyName;
const toTemplateCard = this._addTaskCard(task, cardTitle, osparc.task.ToTemplate.ICON);
if (toTemplateCard) {
this.__attachToTemplateEventHandler(task, toTemplateTaskUI, toTemplateCard);
}
},
// TASKS //
}
});
Original file line number Diff line number Diff line change
Expand Up @@ -1491,7 +1491,7 @@ qx.Class.define("osparc.data.Resources", {
if ("status" in err && err.status === 401) {
// Unauthorized again, the cookie might have expired.
// We can assume that all calls after this will respond with 401, so bring the user ot the login page.
qx.core.Init.getApplication().logout(qx.locale.Manager.tr("You were logged out. Your cookie might have expired."));
qx.core.Init.getApplication().logout(qx.locale.Manager.tr("You have been logged out. Your cookie might have expired."));
}
});
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ qx.Class.define("osparc.data.model.NodeProgressSequence", {

createDisclaimerText: function() {
const disclaimerText = new qx.ui.basic.Atom().set({
label: qx.locale.Manager.tr("Please be patient, this process can take a few minutes ..."),
label: qx.locale.Manager.tr("Please wait, this process may take a few minutes ..."),
padding: [20, 10],
gap: 15,
icon: "@FontAwesome5Solid/exclamation-triangle/16",
Expand Down Expand Up @@ -187,10 +187,10 @@ qx.Class.define("osparc.data.model.NodeProgressSequence", {
getProgress: function(report) {
if (report.unit) {
const attempt = ("attempt" in report && report["attempt"] > 1) ? `(attempt ${report["attempt"]}) ` : "";
const current_value = osparc.utils.Utils.bytesToSize(report["actual_value"], 1, false);
const total_value = osparc.utils.Utils.bytesToSize(report["total"], 1, false)
const currentValue = osparc.utils.Utils.bytesToSize(report["actual_value"], 1, false);
const totalValue = osparc.utils.Utils.bytesToSize(report["total"], 1, false)
return {
progressLabel: `${attempt}${current_value} / ${total_value}`,
progressLabel: `${attempt}${currentValue} / ${totalValue}`,
value: report["actual_value"] / report["total"]
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ qx.Class.define("osparc.desktop.MainPage", {
osparc.data.Resources.fetch("snapshots", "checkout", params)
.then(snapshotResp => {
if (!snapshotResp) {
const msg = this.tr("Snapshot not found");
const msg = this.tr("No snapshot found");
throw new Error(msg);
}
const params2 = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ qx.Class.define("osparc.desktop.account.ProfilePage", {
expirationLayout.add(expirationDateLabel);
const expirationDate = new qx.ui.basic.Label();
expirationLayout.add(expirationDate);
const infoLabel = this.tr("Please contact us by email:<br>");
const infoLabel = this.tr("Please contact us via email:<br>");
const infoExtension = new osparc.ui.hint.InfoHint(infoLabel);
const supportEmail = osparc.store.VendorInfo.getInstance().getSupportEmail();
infoExtension.setHintText(infoLabel + supportEmail);
Expand Down Expand Up @@ -348,7 +348,7 @@ qx.Class.define("osparc.desktop.account.ProfilePage", {
});

const optOutMessage = new qx.ui.basic.Atom().set({
label: this.tr("If all searchable fields are hidden, you will not be findable."),
label: this.tr("If all searchable fields are hidden, you will not be discoverable."),
icon: "@FontAwesome5Solid/exclamation-triangle/14",
gap: 8,
allowGrowX: false,
Expand Down Expand Up @@ -381,7 +381,7 @@ qx.Class.define("osparc.desktop.account.ProfilePage", {
},

__create2FASection: function() {
const box = osparc.ui.window.TabbedView.createSectionBox(this.tr("2 Factor Authentication"));
const box = osparc.ui.window.TabbedView.createSectionBox(this.tr("Two-Factor Authentication"));

const label = osparc.ui.window.TabbedView.createHelpLabel(this.tr("Set your preferred method to use for two-factor authentication when signing in:"));
box.add(label);
Expand Down Expand Up @@ -419,7 +419,7 @@ qx.Class.define("osparc.desktop.account.ProfilePage", {
if (selectedId === "DISABLED") {
const discourageTitle = this.tr("You are about to disable the 2FA");
const discourageText = this.tr("\
The 2 Factor Authentication is one more measure to prevent hackers from accessing your account with an additional layer of security. \
The Two-Factor Authentication is one more measure to prevent hackers from accessing your account with an additional layer of security. \
When you sign in, 2FA helps make sure that your resources and personal information stays private, safe and secure.\
");
const win = new osparc.ui.window.Confirmation(discourageTitle).set({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ qx.Class.define("osparc.desktop.credits.CreditsPerService", {
this._add(uiEntry);
});
} else {
const nothingFound = new qx.ui.basic.Label(this.tr("No usage found")).set({
const nothingFound = new qx.ui.basic.Label(this.tr("No usage records found")).set({
font: "text-14",
padding: 20,
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -243,8 +243,8 @@ qx.Class.define("osparc.desktop.organizations.MembersList", {
const canIDelete = organization.getAccessRights()["delete"];

const introText = canIWrite ?
this.tr("You can add new members and change their roles.") :
this.tr("You can't add new members to this Organization. Please contact an Administrator or Manager.");
this.tr("You can add new members and assign roles.") :
this.tr("You cannot add new members to this Organization. Please contact an Administrator or Manager.");
this.__introLabel.setValue(introText);

this.__addMembersButton.set({
Expand Down Expand Up @@ -508,7 +508,7 @@ qx.Class.define("osparc.desktop.organizations.MembersList", {
} else if (isThereAnyManager) {
rUSure += `<br>There is no ${osparc.data.Roles.ORG[3].label} in this Organization.`;
}
rUSure += "<br><br>" + this.tr("If you Leave, the page will be reloaded.");
rUSure += "<br><br>" + this.tr("If you leave, the page will reload.");
const confirmationWin = new osparc.ui.window.Confirmation(rUSure).set({
caption: this.tr("Leave Organization"),
confirmText: this.tr("Leave"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ qx.Class.define("osparc.desktop.organizations.OrganizationDetails", {
const titleLayout = this.__titleLayout = new qx.ui.container.Composite(new qx.ui.layout.HBox(5));

const prevBtn = new qx.ui.form.Button().set({
toolTipText: this.tr("Back to Organizations list"),
toolTipText: this.tr("Return to Organizations list"),
icon: "@FontAwesome5Solid/arrow-left/20",
backgroundColor: "transparent"
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ qx.Class.define("osparc.desktop.paymentMethods.PaymentMethodDetails", {
members: {
__buildLayout: function(paymentMethodData) {
[
[this.tr("Holder name"), paymentMethodData["cardHolderName"]],
[this.tr("Card Holder name"), paymentMethodData["cardHolderName"]],
[this.tr("Type"), paymentMethodData["cardType"]],
[this.tr("Number"), paymentMethodData["cardNumberMasked"]],
[this.tr("Expiration date"), paymentMethodData["expirationMonth"] + "/" + paymentMethodData["expirationYear"]]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ qx.Class.define("osparc.desktop.paymentMethods.PaymentMethodListItem", {
},

__deletePressed: function() {
const msg = this.tr("Are you sure you want to delete the Payment Method?");
const msg = this.tr("Are you sure you want to delete this Payment Method?");
const win = new osparc.ui.window.Confirmation(msg).set({
caption: this.tr("Delete Payment Method"),
confirmText: this.tr("Delete"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -173,12 +173,12 @@ qx.Class.define("osparc.desktop.preferences.pages.TokensPage", {

__createTokensSection: function() {
// layout
const box = osparc.ui.window.TabbedView.createSectionBox(this.tr("External Service Tokens"));
const box = osparc.ui.window.TabbedView.createSectionBox(this.tr("API Tokens for External Services"));

const label = osparc.ui.window.TabbedView.createHelpLabel(this.tr("Enter the API tokens to access external services."));
const label = osparc.ui.window.TabbedView.createHelpLabel(this.tr("Provide the API tokens needed to access external services."));
box.add(label);

const validTokensGB = this.__validTokensGB = osparc.ui.window.TabbedView.createSectionBox(this.tr("Existing Tokens"));
const validTokensGB = this.__validTokensGB = osparc.ui.window.TabbedView.createSectionBox(this.tr("Current Tokens"));
box.add(validTokensGB);

const supportedExternalsGB = this.__supportedExternalsGB = osparc.ui.window.TabbedView.createSectionBox(this.tr("Supported services")).set({
Expand Down Expand Up @@ -280,7 +280,7 @@ qx.Class.define("osparc.desktop.preferences.pages.TokensPage", {
return;
}

const msg = this.tr("Do you want to delete the Token?");
const msg = this.tr("Are you sure you want to delete this token?");
const win = new osparc.ui.window.Confirmation(msg).set({
caption: this.tr("Delete Token"),
confirmText: this.tr("Delete"),
Expand Down Expand Up @@ -326,13 +326,13 @@ qx.Class.define("osparc.desktop.preferences.pages.TokensPage", {

const newTokenKey = new qx.ui.form.TextField();
newTokenKey.set({
placeholder: this.tr("Input your token key")
placeholder: this.tr("Enter your token key")
});
form.add(newTokenKey, this.tr("Key"));

const newTokenSecret = new qx.ui.form.TextField();
newTokenSecret.set({
placeholder: this.tr("Input your token secret")
placeholder: this.tr("Enter your token secret")
});
form.add(newTokenSecret, this.tr("Secret"));

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ qx.Class.define("osparc.desktop.preferences.window.CreateAPIKey", {
extend: osparc.desktop.preferences.window.APIKeyBase,

construct: function() {
const caption = this.tr("Create API Key");
const caption = this.tr("Generate API Key");
const infoText = this.tr("Key names must be unique.");
this.base(arguments, caption, infoText);

Expand Down Expand Up @@ -48,7 +48,7 @@ qx.Class.define("osparc.desktop.preferences.window.CreateAPIKey", {
if (date) {
// allow only future dates
if (new Date() > new Date(date)) {
const msg = this.tr("Choose a future date");
const msg = this.tr("Select a future date");
osparc.FlashMessenger.logAs(msg, "WARNING");
expirationDate.resetValue();
} else {
Expand Down
Loading
Loading