Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
lti-xblock-consumer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
OpenJupyter
lti-xblock-consumer
Commits
541bb36d
Unverified
Commit
541bb36d
authored
1 year ago
by
Zachary Hancock
Committed by
GitHub
1 year ago
Browse files
Options
Downloads
Patches
Plain Diff
feat: fix and update translate strings (#353)
* feat: translation safe pii dialogue * feat: extract translations
parent
469d47dd
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
CHANGELOG.rst
+1
-0
1 addition, 0 deletions
CHANGELOG.rst
lti_consumer/static/js/xblock_lti_consumer.js
+7
-8
7 additions, 8 deletions
lti_consumer/static/js/xblock_lti_consumer.js
lti_consumer/translations/en/LC_MESSAGES/text.po
+186
-115
186 additions, 115 deletions
lti_consumer/translations/en/LC_MESSAGES/text.po
with
194 additions
and
123 deletions
CHANGELOG.rst
+
1
−
0
View file @
541bb36d
...
...
@@ -15,6 +15,7 @@ Please See the `releases tab <https://github.com/openedx/xblock-lti-consumer/rel
Unreleased
~~~~~~~~~~
* Updated PII JS so strings can be extracted for translation.
9.0.1 - 2023-04-11
------------------
...
...
This diff is collapsed.
Click to expand it.
lti_consumer/static/js/xblock_lti_consumer.js
+
7
−
8
View file @
541bb36d
...
...
@@ -123,9 +123,9 @@ function LtiConsumerXBlock(runtime, element) {
if
(
showCancelButton
)
{
$dialog_container
.
append
(
'
<button style="margin-right:1rem" id="cancel-button">
Cancel
</button>
'
);
.
append
(
'
<button style="margin-right:1rem" id="cancel-button">
'
+
gettext
(
"
Cancel
"
)
+
'
</button>
'
);
}
$dialog_container
.
append
(
'
<button id="confirm-button">
OK
</button>
'
);
$dialog_container
.
append
(
'
<button id="confirm-button">
'
+
gettext
(
'
OK
'
)
+
'
</button>
'
);
// When a learner clicks "OK" or "Cancel" in the consent dialog, remove the consent dialog, show the launch
// button, and resolve the promise.
...
...
@@ -154,21 +154,20 @@ function LtiConsumerXBlock(runtime, element) {
function
renderPIIConsentPromptIfRequired
(
onSuccess
,
showCancelButton
=
true
)
{
if
(
askToSendUsername
&&
askToSendEmail
)
{
msg
=
"
Click OK to have your username and e-mail address sent to a 3rd party application.
"
;
msg
=
gettext
(
'
Click OK to have your username and e-mail address sent to a 3rd party application.
'
)
;
}
else
if
(
askToSendUsername
)
{
msg
=
"
Click OK to have your username sent to a 3rd party application.
"
;
msg
=
gettext
(
'
Click OK to have your username sent to a 3rd party application.
'
)
;
}
else
if
(
askToSendEmail
)
{
msg
=
"
Click OK to have your e-mail address sent to a 3rd party application.
"
;
msg
=
gettext
(
'
Click OK to have your e-mail address sent to a 3rd party application.
'
)
;
}
else
{
onSuccess
(
"
OK
"
);
onSuccess
(
'
OK
'
);
return
;
}
if
(
showCancelButton
)
{
msg
+=
"
\n\n
Click Cancel to return to this page without sending your information.
"
;
msg
+=
'
\n\n
'
+
gettext
(
'
Click Cancel to return to this page without sending your information.
'
)
;
}
msg
=
gettext
(
msg
);
$
.
when
(
confirmDialog
(
msg
,
$
(
this
),
showCancelButton
)).
then
(
onSuccess
);
}
...
...
This diff is collapsed.
Click to expand it.
lti_consumer/translations/en/LC_MESSAGES/text.po
+
186
−
115
View file @
541bb36d
...
...
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 202
2
-0
2-01 17:24
-0
3
00\n"
"POT-Creation-Date: 202
3
-0
4-11 15:09
-0
4
00\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
...
...
@@ -18,99 +18,145 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#: lti_1p3/extensions/rest_framework/authentication.py:4
0
#: lti_1p3/extensions/rest_framework/authentication.py:4
1
msgid "Missing LTI 1.3 authentication token."
msgstr ""
#: lti_1p3/extensions/rest_framework/authentication.py:4
4
#: lti_1p3/extensions/rest_framework/authentication.py:4
5
msgid "Invalid token header. No credentials provided."
msgstr ""
#: lti_1p3/extensions/rest_framework/authentication.py:4
8
#: lti_1p3/extensions/rest_framework/authentication.py:4
9
msgid "Invalid token header. Token string should not contain spaces."
msgstr ""
#: lti_1p3/extensions/rest_framework/authentication.py:5
6
#: lti_1p3/extensions/rest_framework/authentication.py:5
7
msgid "LTI configuration not found."
msgstr ""
#: lti_1p3/extensions/rest_framework/authentication.py:6
5
#: lti_1p3/extensions/rest_framework/authentication.py:6
6
msgid "Invalid token signature."
msgstr ""
#: lti_xblock.py:12
7
#: lti_xblock.py:12
6
msgid "No valid user id found in endpoint URL"
msgstr ""
#: lti_xblock.py:233
#: lti_xblock.py:139
msgid "Configuration on block"
msgstr ""
#: lti_xblock.py:143
msgid "Database Configuration"
msgstr ""
#: lti_xblock.py:146
msgid "Reusable Configuration"
msgstr ""
#: lti_xblock.py:253
msgid "Display Name"
msgstr ""
#: lti_xblock.py:2
3
5
#: lti_xblock.py:2
5
5
msgid ""
"Enter the name that students see for this component. Analytics reports may "
"also use the display name to identify this component."
msgstr ""
#: lti_xblock.py:2
3
9
#: lti_xblock.py:2
5
9
msgid "LTI Consumer"
msgstr ""
#: lti_xblock.py:2
4
2
#: lti_xblock.py:2
6
2
msgid "LTI Application Information"
msgstr ""
#: lti_xblock.py:2
4
4
#: lti_xblock.py:2
6
4
msgid ""
"Enter a description of the third party application. If requesting username "
"and/or email, use this text box to inform users why their username and/or "
"email will be forwarded to a third party application."
msgstr ""
#: lti_xblock.py:254
#: lti_xblock.py:272
msgid "Configuration Type"
msgstr ""
#: lti_xblock.py:277
msgid ""
"Select 'Configuration on block' to configure a new LTI Tool. If the support "
"staff provided you with a pre-configured LTI reusable Tool ID, "
"select'Reusable Configuration' and enter it in the text field below."
msgstr ""
#: lti_xblock.py:284
msgid "LTI Version"
msgstr ""
#: lti_xblock.py:2
6
2
#: lti_xblock.py:2
9
2
msgid ""
"Select the LTI version that your tool supports.<br />The XBlock LTI Consumer "
"fully supports LTI 1.1.1, LTI 1.3 and LTI Advantage features."
msgstr ""
#: lti_xblock.py:268
#: lti_xblock.py:299
msgid "LTI Reusable Configuration ID"
msgstr ""
#: lti_xblock.py:301
msgid ""
"Enter the reusable LTI external configuration ID provided by the support "
"staff."
msgstr ""
#: lti_xblock.py:306
msgid "Tool Launch URL"
msgstr ""
#: lti_xblock.py:
272
#: lti_xblock.py:
310
msgid ""
"Enter the LTI 1.3 Tool Launch URL. <br />This is the URL the LMS will use to "
"launch the LTI Tool."
msgstr ""
#: lti_xblock.py:
277
#: lti_xblock.py:
315
msgid "Tool Initiate Login URL"
msgstr ""
#: lti_xblock.py:
281
#: lti_xblock.py:
319
msgid ""
"Enter the LTI 1.3 Tool OIDC Authorization url (can also be called login or "
"login initiation URL).<br />This is the URL the LMS will use to start a LTI "
"authorization prior to doing the launch request."
msgstr ""
#: lti_xblock.py:288
#: lti_xblock.py:325
msgid "Registered Redirect URIs"
msgstr ""
#: lti_xblock.py:327
msgid ""
"Valid urls the Tool may request us to redirect the id token to. The redirect "
"uris are often the same as the launch url/deep linking url so if this field "
"is empty, it will use them as the default. If you need to use different "
"redirect uri's, enter them here. If you use this field you must enter all "
"valid redirect uri's the tool may request."
msgstr ""
#: lti_xblock.py:337
msgid "Tool Public Key Mode"
msgstr ""
#: lti_xblock.py:
296
#: lti_xblock.py:
345
msgid "Select how the tool's public key information will be specified."
msgstr ""
#: lti_xblock.py:3
00
#: lti_xblock.py:3
49
msgid "Tool Keyset URL"
msgstr ""
#: lti_xblock.py:3
04
#: lti_xblock.py:3
53
msgid ""
"Enter the LTI 1.3 Tool's JWK keysets URL.<br />This link should retrieve a "
"JSON file containing public keys and signature algorithm information, so "
...
...
@@ -119,11 +165,11 @@ msgid ""
"Launches without LTI Advantage nor Basic Outcomes requests.</b>"
msgstr ""
#: lti_xblock.py:3
14
#: lti_xblock.py:3
63
msgid "Tool Public Key"
msgstr ""
#: lti_xblock.py:3
19
#: lti_xblock.py:3
68
msgid ""
"Enter the LTI 1.3 Tool's public key.<br />This is a string that starts with "
"'-----BEGIN PUBLIC KEY-----' and is required so that the LMS can check if "
...
...
@@ -132,61 +178,61 @@ msgid ""
"Advantage nor Basic Outcomes requests.</b>"
msgstr ""
#: lti_xblock.py:3
29
#: lti_xblock.py:3
78
msgid "Enable LTI NRPS"
msgstr ""
#: lti_xblock.py:3
30
#: lti_xblock.py:3
79
msgid "Enable LTI Names and Role Provisioning Services."
msgstr ""
#: lti_xblock.py:3
37
#: lti_xblock.py:3
86
msgid "LTI 1.3 Block Client ID - DEPRECATED"
msgstr ""
#: lti_xblock.py:3
40
#: lti_xblock.py:3
89
msgid "DEPRECATED - This is now stored in the LtiConfiguration model."
msgstr ""
#: lti_xblock.py:3
43
#: lti_xblock.py:3
92
msgid "LTI 1.3 Block Key - DEPRECATED"
msgstr ""
#: lti_xblock.py:3
50
#: lti_xblock.py:3
99
msgid "Deep linking"
msgstr ""
#: lti_xblock.py:
351
#: lti_xblock.py:
400
msgid "Select True if you want to enable LTI Advantage Deep Linking."
msgstr ""
#: lti_xblock.py:
356
#: lti_xblock.py:
405
msgid "Deep Linking Launch URL"
msgstr ""
#: lti_xblock.py:
360
#: lti_xblock.py:
409
msgid ""
"Enter the LTI Advantage Deep Linking Launch URL. If the tool does not "
"specify one, use the same value as 'Tool Launch URL'."
msgstr ""
#: lti_xblock.py:
365
#: lti_xblock.py:
414
msgid "LTI Assignment and Grades Service"
msgstr ""
#: lti_xblock.py:
367
#: lti_xblock.py:
416
msgid "Disabled"
msgstr ""
#: lti_xblock.py:
368
#: lti_xblock.py:
417
msgid "Allow tools to submit grades only (declarative)"
msgstr ""
#: lti_xblock.py:
369
#: lti_xblock.py:
418
msgid "Allow tools to manage and submit grade (programmatic)"
msgstr ""
#: lti_xblock.py:
374
#: lti_xblock.py:
423
msgid ""
"Enable the LTI-AGS service and select the functionality enabled for LTI "
"tools. The 'declarative' mode (default) will provide a tool with a LineItem "
...
...
@@ -194,11 +240,11 @@ msgid ""
"tools to manage, create and link the grades."
msgstr ""
#: lti_xblock.py:
382
#: lti_xblock.py:
431
msgid "LTI ID"
msgstr ""
#: lti_xblock.py:
384
#: lti_xblock.py:
433
#, python-brace-format
msgid ""
"Enter the LTI ID for the external LTI provider. This value must be the same "
...
...
@@ -207,11 +253,11 @@ msgid ""
"documentation{anchor_close} for more details on this setting."
msgstr ""
#: lti_xblock.py:
396
#: lti_xblock.py:
445
msgid "LTI URL"
msgstr ""
#: lti_xblock.py:
398
#: lti_xblock.py:
447
#, python-brace-format
msgid ""
"Enter the URL of the external tool that this component launches. This "
...
...
@@ -220,11 +266,11 @@ msgid ""
"this setting."
msgstr ""
#: lti_xblock.py:4
11
#: lti_xblock.py:4
60
msgid "Custom Parameters"
msgstr ""
#: lti_xblock.py:4
13
#: lti_xblock.py:4
62
#, python-brace-format
msgid ""
"Add the key/value pair for any custom parameters, such as the page your e-"
...
...
@@ -233,11 +279,11 @@ msgid ""
"documentation{anchor_close} for more details on this setting."
msgstr ""
#: lti_xblock.py:42
3
#: lti_xblock.py:4
7
2
msgid "LTI Launch Target"
msgstr ""
#: lti_xblock.py:4
25
#: lti_xblock.py:4
74
msgid ""
"Select Inline if you want the LTI content to open in an IFrame in the "
"current page. Select Modal if you want the LTI content to open in a modal "
...
...
@@ -246,210 +292,226 @@ msgid ""
"Tool is set to False."
msgstr ""
#: lti_xblock.py:4
39
#: lti_xblock.py:4
88
msgid "Button Text"
msgstr ""
#: lti_xblock.py:4
41
#: lti_xblock.py:4
90
msgid ""
"Enter the text on the button used to launch the third party application. "
"This setting is only used when Hide External Tool is set to False and LTI "
"Launch Target is set to Modal or New Window."
msgstr ""
#: lti_xblock.py:4
4
9
#: lti_xblock.py:49
8
msgid "Inline Height"
msgstr ""
#: lti_xblock.py:
451
#: lti_xblock.py:
500
msgid ""
"Enter the desired pixel height of the iframe which will contain the LTI "
"tool. This setting is only used when Hide External Tool is set to False and "
"LTI Launch Target is set to Inline."
msgstr ""
#: lti_xblock.py:
459
#: lti_xblock.py:
508
msgid "Modal Height"
msgstr ""
#: lti_xblock.py:
461
#: lti_xblock.py:
510
msgid ""
"Enter the desired viewport percentage height of the modal overlay which will "
"contain the LTI tool. This setting is only used when Hide External Tool is "
"set to False and LTI Launch Target is set to Modal."
msgstr ""
#: lti_xblock.py:
469
#: lti_xblock.py:
518
msgid "Modal Width"
msgstr ""
#: lti_xblock.py:
471
#: lti_xblock.py:
520
msgid ""
"Enter the desired viewport percentage width of the modal overlay which will "
"contain the LTI tool. This setting is only used when Hide External Tool is "
"set to False and LTI Launch Target is set to Modal."
msgstr ""
#: lti_xblock.py:
479
#: lti_xblock.py:
528
msgid "Scored"
msgstr ""
#: lti_xblock.py:
480
#: lti_xblock.py:
529
msgid ""
"Select True if this component will receive a numerical score from the "
"external LTI system."
msgstr ""
#: lti_xblock.py:
487
#: lti_xblock.py:
536
msgid ""
"Enter the number of points possible for this component. The default value "
"is 1.0. This setting is only used when Scored is set to True."
msgstr ""
#: lti_xblock.py:
496
#: lti_xblock.py:
545
msgid ""
"The score kept in the xblock KVS -- duplicate of the published score in "
"django DB"
msgstr ""
#: lti_xblock.py:50
1
#: lti_xblock.py:5
5
0
msgid "Comment as returned from grader, LTI2.0 spec"
msgstr ""
#: lti_xblock.py:5
06
#: lti_xblock.py:5
55
msgid "Hide External Tool"
msgstr ""
#: lti_xblock.py:5
08
#: lti_xblock.py:5
57
msgid ""
"Select True if you want to use this component as a placeholder for syncing "
"with an external grading system rather than launch an external tool. This "
"setting hides the Launch button and any IFrames for this component."
msgstr ""
#: lti_xblock.py:5
1
6
#: lti_xblock.py:56
5
msgid "Accept grades past deadline"
msgstr ""
#: lti_xblock.py:5
17
#: lti_xblock.py:5
66
msgid ""
"Select True to allow third party systems to post grades past the deadline."
msgstr ""
#: lti_xblock.py:5
25
#: lti_xblock.py:5
74
msgid "Request user's username"
msgstr ""
#. Translators: This is used to request the user's username for a third party service.
#: lti_xblock.py:5
2
7
#: lti_xblock.py:57
6
msgid "Select True to request the user's username."
msgstr ""
#: lti_xblock.py:5
32
#: lti_xblock.py:5
81
msgid "Request user's email"
msgstr ""
#. Translators: This is used to request the user's email for a third party service.
#: lti_xblock.py:53
4
#: lti_xblock.py:5
8
3
msgid "Select True to request the user's email address."
msgstr ""
#: lti_xblock.py:5
39
#: lti_xblock.py:5
88
msgid "Send extra parameters"
msgstr ""
#: lti_xblock.py:5
40
#: lti_xblock.py:5
89
msgid ""
"Select True to send the extra parameters, which might contain Personally "
"Identifiable Information. The processors are site-wide, please consult the "
"site administrator if you have any questions."
msgstr ""
#: lti_xblock.py:6
03
#: lti_xblock.py:6
52
msgid "Custom Parameters must be a list"
msgstr ""
#: lti_xblock.py:713
#: lti_xblock.py:783 lti_xblock.py:1062
msgid "Could not get user data for current request"
msgstr ""
#: lti_xblock.py:810
msgid ""
"Could not parse LTI passport: {lti_passport!r}. Should be \"id:key:secret\" "
"string."
msgstr ""
#: lti_xblock.py:
729
lti_xblock.py:
745
#: lti_xblock.py:
828
lti_xblock.py:
842 lti_xblock.py:858
msgid "Could not get user id for current request"
msgstr ""
#: lti_xblock.py:
850
#: lti_xblock.py:
994
msgid ""
"Could not parse custom parameter: {custom_parameter!r}. Should be \"x=y\" "
"string."
msgstr ""
#: lti_xblock.py:13
10
#: lti_xblock.py:13
43
msgid "[LTI]: Real user not found against anon_id: {}"
msgstr ""
#: models.py:7
2
#: models.py:7
9
msgid "Configuration Stored on XBlock fields"
msgstr ""
#: models.py:
73
#: models.py:
80
msgid "Configuration Stored on this model"
msgstr ""
#: models.py:97
#: models.py:81
msgid "Configuration Stored on external service"
msgstr ""
#: models.py:113
msgid "LTI configuration data."
msgstr ""
#: models.py:10
4
#: models.py:1
2
0
msgid "The URL of the external tool that initiates the launch."
msgstr ""
#: models.py:1
09
#: models.py:1
25
msgid "Client key provided by the LTI tool provider."
msgstr ""
#: models.py:11
5
#: models.py:1
3
1
msgid "Client secret provided by the LTI tool provider."
msgstr ""
#: models.py:1
21
#: models.py:1
37
msgid "Platform's generated Private key. Keep this value secret."
msgstr ""
#: models.py:1
27
#: models.py:1
43
msgid "Platform's generated Private key ID"
msgstr ""
#: models.py:1
32
#: models.py:1
48
msgid "Platform's generated JWK keyset."
msgstr ""
#: models.py:1
38
#: models.py:1
54
msgid "Client ID used by LTI tool"
msgstr ""
#: models.py:
148
#: models.py:
250
msgid "LTI Configuration stores on XBlock needs a block location set."
msgstr ""
#: models.py:155
msgid "Invalid LTI configuration."
#: models.py:256
msgid ""
"LTI Configuration stored on the model for LTI 1.3 must have a value for one "
"of lti_1p3_tool_public_key or lti_1p3_tool_keyset_url."
msgstr ""
#: models.py:165
msgid "Block location not set, it's not possible to retrieve the block."
#: models.py:263
msgid ""
"CONFIG_ON_XBLOCK and CONFIG_EXTERNAL are not supported for LTI 1.3 "
"Proctoring Services."
msgstr ""
#: plugin/views.py:246
#: models.py:271
msgid "Invalid LTI configuration."
msgstr ""
#: plugin/views.py:453
msgid "The selected content type is not supported by Open edX."
msgstr ""
#: plugin/views.py:
261
#: plugin/views.py:
468
msgid "You don't have access to save LTI Content Items."
msgstr ""
#: plugin/views.py:
262
#: plugin/views.py:
469
msgid ""
"Please check that you have course staff permissions and double check this "
"block's LTI settings."
...
...
@@ -471,15 +533,6 @@ msgstr ""
msgid "You can safely close this page now."
msgstr ""
#: templates/html/lti_1p3_launch_error.html:10
msgid "There was an error while launching the LTI 1.3 tool."
msgstr ""
#: templates/html/lti_1p3_launch_error.html:13
msgid ""
"If you're seeing this on a live course, please contact the course staff."
msgstr ""
#: templates/html/lti_1p3_permission_error.html:10
msgid "Unauthorized."
msgstr ""
...
...
@@ -548,24 +601,42 @@ msgstr ""
msgid "Press to Launch"
msgstr ""
#: static/js/xblock_lti_consumer.js:142
msgid ""
"Click OK to have your username and e-mail address sent to a 3rd party "
"application.\n"
"\n"
"Click Cancel to return to this page without sending your information."
#: templates/html/lti_launch_error.html:10
msgid "There was an error while launching the LTI tool."
msgstr ""
#: static/js/xblock_lti_consumer.js:144
#: templates/html/lti_launch_error.html:13
#: templates/html/lti_proctoring_start_error.html:13
msgid ""
"Click OK to have your username sent to a 3rd party application.\n"
"\n"
"Click Cancel to return to this page without sending your information."
"If you're seeing this on a live course, please contact the course staff."
msgstr ""
#: static/js/xblock_lti_consumer.js:146
#: templates/html/lti_proctoring_start_error.html:10
msgid "There was an error while starting your LTI proctored assessment."
msgstr ""
#: static/js/xblock_lti_consumer.js:126
msgid "Cancel"
msgstr ""
#: static/js/xblock_lti_consumer.js:128
msgid "OK"
msgstr ""
#: static/js/xblock_lti_consumer.js:157
msgid ""
"Click OK to have your e-mail address sent to a 3rd party application.\n"
"\n"
"Click Cancel to return to this page without sending your information."
"Click OK to have your username and e-mail address sent to a 3rd party "
"application."
msgstr ""
#: static/js/xblock_lti_consumer.js:159
msgid "Click OK to have your username sent to a 3rd party application."
msgstr ""
#: static/js/xblock_lti_consumer.js:161
msgid "Click OK to have your e-mail address sent to a 3rd party application."
msgstr ""
#: static/js/xblock_lti_consumer.js:168
msgid "Click Cancel to return to this page without sending your information."
msgstr ""
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment