Skip to content

Commit c5b2b9a

Browse files
authored
Merge pull request #5711 from Countly/SER-1129
[SER-1129] remove HTML from localisation files
2 parents 025d669 + 2ada807 commit c5b2b9a

File tree

28 files changed

+137
-90
lines changed

28 files changed

+137
-90
lines changed

frontend/express/public/core/events/javascripts/countly.details.models.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -544,6 +544,10 @@
544544
if (eventsLength >= limits.event_limit) {
545545
eventLimit.message = CV.i18n("events.max-event-key-limit", limits.event_limit);
546546
eventLimit.show = true;
547+
eventLimit.goTo = {
548+
title: CV.i18n("common.go-to-settings"),
549+
url: "#/manage/configurations/api"
550+
};
547551
limitAlert.push(eventLimit);
548552
}
549553
if (!context.state.selectedEventName.startsWith('[CLY]_group')) {

frontend/express/public/core/events/templates/allEvents.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
</div>
2929
<div class="bu-column bu-is-9">
3030
<div class="bu-mr-5 cly-vue-events-alerts" v-for="item in limitAlerts" :key="item" :value="item">
31-
<cly-notification v-if="item.show" class="bu-mb-5 cly-vue-events-all__alerts" :text="item.message" color="light-warning">
31+
<cly-notification v-if="item.show" class="bu-mb-5 cly-vue-events-all__alerts" :text="item.message" :goTo="item.goTo" color="light-warning">
3232
</cly-notification>
3333
</div>
3434
<div class="cly-vue-events-all" v-if="!groupData.isGroup" data-test-id="event-title">

frontend/express/public/javascripts/countly/countly.helpers.js

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -341,6 +341,7 @@
341341
payload.autoHide = !msg.sticky;
342342
payload.id = msg.id;
343343
payload.width = msg.width;
344+
payload.goTo = msg.goTo;
344345
var colorToUse;
345346

346347
if (countlyGlobal.ssr) {
@@ -393,9 +394,14 @@
393394
* title is the text that will be dispalyed for the backlink url.
394395
*/
395396
CountlyHelpers.goTo = function(options) {
396-
app.backlinkUrl = options.from;
397-
app.backlinkTitle = options.title;
398-
window.location.hash = options.url;
397+
if (options.isExternalLink) {
398+
window.open(options.url, '_blank', 'noopener,noreferrer');
399+
}
400+
else {
401+
app.backlinkUrl = options.from;
402+
app.backlinkTitle = options.title;
403+
window.location.hash = options.url;
404+
}
399405
};
400406

401407
/**

frontend/express/public/javascripts/countly/countly.task.manager.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,11 @@
313313
CountlyHelpers.notify({
314314
message: CV.i18n("assistant.taskmanager.longTaskAlreadyRunning.title") + " " + CV.i18n("assistant.taskmanager.longTaskAlreadyRunning.message"),
315315
info: CV.i18n("assistant.taskmanager.longTaskTooLong.info"),
316-
type: "info"
316+
type: "info",
317+
goTo: {
318+
title: CV.i18n("common.go-to-task-manager"),
319+
url: "#/manage/tasks"
320+
}
317321
});
318322
},
319323
completed: function(fetchedTasks) {

frontend/express/public/javascripts/countly/vue/components/helpers.js

Lines changed: 36 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -986,33 +986,35 @@
986986
:class="dynamicClasses"
987987
>
988988
<div class="bu-is-flex bu-is-justify-content-space-between bu-p-3">
989-
<div class="bu-is-flex">
989+
<div class="bu-is-flex" style="width:100%">
990990
<img
991991
class="alert-image bu-mr-3"
992992
data-test-id="cly-notification-img"
993993
:src="image"
994994
>
995-
<slot>
995+
<div :style="dynamicStyle">
996+
<slot>
997+
<span
998+
class="alert-text"
999+
data-test-id="cly-notification-text"
1000+
style="margin-block:auto"
1001+
v-html="innerText"
1002+
>
1003+
{{ text }}
1004+
</span>
1005+
</slot>
9961006
<span
997-
class="alert-text"
998-
data-test-id="cly-notification-text"
999-
style="margin-block:auto"
1000-
v-html="innerText"
1007+
v-if="goTo.title"
1008+
class="bu-is-flex cursor-pointer"
10011009
>
1002-
{{ text }}
1010+
<a
1011+
class="bu-level-item bu-has-text-link bu-has-text-weight-medium"
1012+
@click="goToUrl"
1013+
>
1014+
{{ goTo.title }}
1015+
</a>
10031016
</span>
1004-
</slot>
1005-
</div>
1006-
<div
1007-
v-if="goTo.title"
1008-
class="bu-is-flex bu-ml-auto"
1009-
>
1010-
<a
1011-
class="bu-level-item bu-has-text-link bu-has-text-weight-medium"
1012-
@click="goToUrl"
1013-
>
1014-
{{ goTo.title }}
1015-
</a>
1017+
</div>
10161018
</div>
10171019
<div v-if="closable">
10181020
<div
@@ -1050,6 +1052,7 @@
10501052
type: Object
10511053
},
10521054
customWidth: { default: "", type: String },
1055+
toast: { default: false, type: Boolean }
10531056
},
10541057
data: function() {
10551058
return {
@@ -1112,6 +1115,20 @@
11121115
return this.text;
11131116
}
11141117
return "";
1118+
},
1119+
dynamicStyle: function() {
1120+
let style = {
1121+
"display": "flex",
1122+
"flex-direction": this.toast ? "column" : "row",
1123+
"width": "100%"
1124+
};
1125+
if (this.toast) {
1126+
style.gap = "5px";
1127+
}
1128+
else {
1129+
style["justify-content"] = "space-between";
1130+
}
1131+
return style;
11151132
}
11161133
},
11171134
methods: {

frontend/express/public/javascripts/countly/vue/core.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -713,7 +713,7 @@
713713

714714
var NotificationToastsView = {
715715
template: '<div class="notification-toasts"> \
716-
<cly-notification v-for="(toast) in notificationToasts" :key="toast.id" :id="toast.id" :text="toast.text" :autoHide="toast.autoHide" :color="toast.color" :closable="true" :customWidth="toast.width" @close="onClose" class="notification-toasts__item"></cly-notification>\
716+
<cly-notification v-for="(toast) in notificationToasts" :key="toast.id" :id="toast.id" :text="toast.text" :goTo="toast.goTo" :autoHide="toast.autoHide" :color="toast.color" :closable="true" :customWidth="toast.width" :toast="true" @close="onClose" class="notification-toasts__item"></cly-notification>\
717717
</div>',
718718
store: _vuex.getGlobalStore(),
719719
computed: {

frontend/express/public/localization/dashboard/dashboard.properties

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -233,8 +233,8 @@ common.custom-events = Custom Events
233233
common.none = None
234234
common.emtpy-view-title = ...hmm, seems empty here
235235
common.emtpy-view-subtitle = No data found
236-
common.no-widget-text = Add a widget to create dashboard and see <br/> some informative explanation
237-
common.no-dashboard-text = Create dashboard and see<br/> some informative explanation
236+
common.no-widget-text = Add a widget to create dashboard and see some informative explanation
237+
common.no-dashboard-text = Create dashboard and see some informative explanation
238238
common.create-dashboard = + Create a Dashboard
239239
common.add-widget = + Add a Widget
240240
common.sunday = Sunday
@@ -257,6 +257,9 @@ common.select-all-with-count = Select all {0}
257257
common.deselect = Deselect
258258
common.session = Session
259259
common.sessions = Sessions
260+
common.go-to-settings = Go to settings
261+
common.go-to-app-settings = Go to application management
262+
common.go-to-task-manager = Go to Task Manager
260263

261264
#vue
262265
common.undo = Undo
@@ -348,7 +351,7 @@ assistant.taskmanager.longTaskTooLong.title = This request is running for too lo
348351
assistant.taskmanager.longTaskTooLong.message = We have switched it to report manager and will notify you when it is finished.
349352
assistant.taskmanager.longTaskTooLong.info = Check its status in Utilities -> Report Manager
350353
assistant.taskmanager.longTaskAlreadyRunning.title = A similar report is already running.
351-
assistant.taskmanager.longTaskAlreadyRunning.message = Looks like report with same parameters already running in <a href='#/manage/tasks'>report manager</a>
354+
assistant.taskmanager.longTaskAlreadyRunning.message = Looks like report with same parameters already running in report manager
352355
assistant.taskmanager.completed.title = Report completed for {1}
353356
assistant.taskmanager.completed.message = Results are ready for {0} reports. Check report manager to view them.
354357
assistant.taskmanager.errored.title = Failed to generate report for {0}
@@ -706,9 +709,9 @@ events.top-events.24hours = 24-Hours
706709
events.top-events.30days = 30-Days
707710
events.top-events.yesterday = Yesterday
708711
events.top-events.info-text = Updated {0} hrs ago
709-
events.max-event-key-limit = Maximum limit of unique event keys ({0}) has been reached. Limit can be <a href="/dashboard#/manage/configurations/api">adjusted</a>.
710-
events.max-segmentation-limit = Maximum limit of segmentations ({0}) in current event "{1}" has been reached. Limit can be <a href="/dashboard#/manage/configurations/api">adjusted</a>.
711-
events.max-unique-value-limit = Maximum limit of unique values ({0}) in current event segmentation "{1}" has been reached. Limit can be <a href="/dashboard#/manage/configurations/api">adjusted</a>.
712+
events.max-event-key-limit = Maximum limit of unique event keys ({0}) has been reached. Limit can be adjusted.
713+
events.max-segmentation-limit = Maximum limit of segmentations ({0}) in current event "{1}" has been reached. Limit can be adjusted.
714+
events.max-unique-value-limit = Maximum limit of unique values ({0}) in current event segmentation "{1}" has been reached. Limit can be adjusted.
712715

713716
events.event-group-drawer-create = Create new Event Group
714717
events.event-group-name = Event Group name
@@ -799,9 +802,9 @@ management-applications.app-locked = Application is locked.
799802
management-applications.icon-error = Only jpg, png and gif image formats are allowed
800803
management-applications.no-app-warning = In order to start collecting data you need to add an application to your account.
801804
management-applications.app-key-change-warning-title = Changing the App key
802-
management-applications.app-key-change-warning = Changing the app key will cause all users from this point on to be recorded as new users even if they used your application before. <br/><br/>This action is only recommended if you are migrating an application from another server or changing the app key of a new application.
805+
management-applications.app-key-change-warning = Changing the app key will cause all users from this point on to be recorded as new users even if they used your application before. This action is only recommended if you are migrating an application from another server or changing the app key of a new application.
803806
management-applications.app-key-change-warning-confirm = Continue, change the app key
804-
management-applications.app-key-change-warning-EE = Changing the app key will cause all users from this point on to be recorded as new users even if they used your application before. <br/><br/>This action is only recommended if you are migrating an application from another server or changing the app key of a new application. <br/><br/>If your intention was to change the app key to stop collecting data for this application, recommended way of doing so is using Filtering Rules plugin.
807+
management-applications.app-key-change-warning-EE = Changing the app key will cause all users from this point on to be recorded as new users even if they used your application before. This action is only recommended if you are migrating an application from another server or changing the app key of a new application. If your intention was to change the app key to stop collecting data for this application, recommended way of doing so is using Filtering Rules plugin.
805808
management-applications.first-app-message2 = Great\! You can now embed Countly SDK into your application and start viewing your stats instantly. Don't forget to get your App Key from above.
806809
management-applications.types.mobile = Mobile
807810
management-applications.checksum-salt = Salt for checksum
@@ -1090,7 +1093,7 @@ token_manager.table.expiration-description = Set expiration time for token
10901093
token_manager.table.purpose = Description
10911094
token_manager.table.token-description = Token Description
10921095
token_manager.table.purpose-desc = Some information to help user identify created token.
1093-
token_manager.table.endpoint-desc = You can limit token to a single or multiple endpoints.<br/>Given endpoints are interpreted as regular expressions.
1096+
token_manager.table.endpoint-desc = You can limit token to a single or multiple endpoints. Given endpoints are interpreted as regular expressions.
10941097
token_manager.table.multi-desc = Token can be used multiple times
10951098
token_manager.table.apps-title = Token Usage
10961099
token_manager.table.apps-limit = Allow token to be used only in some apps
@@ -1126,8 +1129,8 @@ token_manager.parameter = Parameter
11261129
token_manager.select-apps = Select Apps
11271130
token_manager.select-time-unit = Select time unit
11281131
token_manager.token-expiration-time = Expiration Time
1129-
token_manager.LoginAuthToken-description = This token is created when creating dashboard screenshots. <br/>If you are not currently rendering dashboard images, you can delete this token.
1130-
token_manager.LoggedInAuth-description = This token is used for keeping users session.<br/> Deleting it will log out user currently using it to keep session.
1132+
token_manager.LoginAuthToken-description = This token is created when creating dashboard screenshots. If you are not currently rendering dashboard images, you can delete this token.
1133+
token_manager.LoggedInAuth-description = This token is used for keeping users session. Deleting it will log out user currently using it to keep session.
11311134

11321135

11331136
version_history.page-title = Countly version history

plugins/alerts/frontend/public/localization/alerts.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ alert.add-number=Add Number
8080
alert.add-alert=Add Alert
8181
alert.save-alert=Save Alert
8282
alert.save=Create
83-
alert.tips = Overview of all alerts set up. Create new alerts to receive emails when<br/> specific conditions related to metrics are met.
83+
alert.tips = Overview of all alerts set up. Create new alerts to receive emails when specific conditions related to metrics are met.
8484
alerts.application-tooltip= Data Points is the only data type available for your selected Application.
8585
alerts.update-status-success = Successfully update status
8686
alerts.save-alert-success= Alert saved

plugins/crashes/frontend/public/localization/crashes.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
crashes.title = Crashes
33
crashes.plugin-title = Crash analytics
44
crashes.plugin-description = See actionable information about crashes and exceptions including which users are impacted
5-
crashes.not-found = This crash report cannot be viewed. Possible reasons:<br/><br/>You are trying to view a crash report that you do not have access to or<br/>Link to this crash is invalid.
5+
crashes.not-found = This crash report cannot be viewed. Possible reasons: You are trying to view a crash report that you do not have access to or the link to this crash is invalid.
66
crashes.search = Search for Error
77
crashes.all = All
88
crashes.show = Show

plugins/dashboards/frontend/public/localization/dashboards.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ dashboards.duplicate-dashboard = Duplicate
117117

118118
dashboards.yes-delete-dashboard = Yes, delete dashboard
119119
dashboards.delete-dashboard-title = Delete dashboard?
120-
dashboards.delete-dashboard-text = Do you really want to delete dashboard called <b> {0} </b>?
120+
dashboards.delete-dashboard-text = Do you really want to delete dashboard called {0} ?
121121
dashbaords.created = Created
122122
dashbaords.created-by = by {0}
123123

0 commit comments

Comments
 (0)