diff --git a/extensions/freebase/module/MOD-INF/controller.js b/extensions/freebase/module/MOD-INF/controller.js
index 206e395c9..d3a37f84a 100644
--- a/extensions/freebase/module/MOD-INF/controller.js
+++ b/extensions/freebase/module/MOD-INF/controller.js
@@ -59,6 +59,7 @@ function init() {
RS.registerCommand(module, "import-qa-data", new Packages.com.google.refine.freebase.commands.ImportQADataCommand());
RS.registerCommand(module, "mqlread", new Packages.com.google.refine.freebase.commands.MQLReadCommand());
RS.registerCommand(module, "mqlwrite", new Packages.com.google.refine.freebase.commands.MQLWriteCommand());
+ RS.registerCommand(module, "load-language", new Packages.com.google.refine.freebase.commands.LoadLanguageCommand());
var OR = Packages.com.google.refine.operations.OperationRegistry;
diff --git a/extensions/freebase/module/langs/translation-default.json b/extensions/freebase/module/langs/translation-default.json
new file mode 100644
index 000000000..f40a6d384
--- /dev/null
+++ b/extensions/freebase/module/langs/translation-default.json
@@ -0,0 +1,115 @@
+{
+ "fb-schema-alignment": {
+ "close-confirm": "There are unsaved changes. Close anyway?",
+ "status-warning": "There are unsaved changes.",
+ "assert-link-found": "Assert link when 'true' is found in column",
+ "search-pick-property": "Search for a property or pick one below",
+ "search-property": "Search for a property",
+ "cell": "cell",
+ "cells": "cells",
+ "which-column": "Which column?",
+ "configure": "Configure...",
+ "which-topic": "Which topic?",
+ "what-value": "What value?",
+ "anonymous": "anonymous",
+ "add-property": "add property",
+ "anonymous-node": "Anonymous Node",
+ "freebase-topic": "Freebase Topic",
+ "value": "Value",
+ "skeleton-node": "Schema Alignment Skeleton Node",
+ "text": "text",
+ "int": "int",
+ "float": "float",
+ "double": "double",
+ "boolean": "boolean",
+ "date-time": "date/time",
+ "rawstring": "rawstring",
+ "set-to-cell": "Set to Cell in Column",
+ "cell-content-used": "The cell's content is used ...",
+ "specify-fb-topic": "to specify a Freebase topic, as reconciled",
+ "type-new-topics": "Type new topics as",
+ "literal-value": "as a literal value",
+ "literal-type": "Literal type",
+ "text-language": "Text language",
+ "key-namespace": "as a key in a namespace",
+ "namespace": "Namespace",
+ "generate-anonymous": "Generate an anonymous graph node",
+ "assign-type": "Assign a type to the node",
+ "use-existing-topic": "Use one existing Freebase topic",
+ "value-type": "Value type",
+ "language": "Language",
+ "use-literal-value": "Use a literal value",
+ "column-warning": "You must select at least one column",
+ "new-node-warning": "For creating a new graph node, you need to specify a type for it.",
+ "namespace-warning": "Please specify the namespace.",
+ "anonymous-node-warning": "For generating an anonymous graph node, you need to specify a type for it",
+ "specify-topic-warning": "Please specify which existing Freebase topic to use",
+ "specify-value-warning": "Please specify the value to use"
+ },
+ "fb-interface": {
+ "dialog-header": "Align to Freebase's Schemas",
+ "body-text": "The schema alignment skeleton below specifies how your grid-shaped data will be transformed into graph-shaped data in Freebase's schemas.",
+ "find-more": "Find out more ...",
+ "skeleton": "Skeleton",
+ "mql-preview": "MQL-like Preview",
+ "tripleloader-preview": "TripleLoader Preview"
+ },
+ "fb-dialogs": {
+ "sign-in": "Sign into Freebase",
+ "enable-loading": "to enable loading",
+ "error-new-topic": "Error creating new topic",
+ "error-loading-data": "Error loading data",
+ "add-info-source": "Click here to add a new information source",
+ "dialog-header": "Load Data into Freebase",
+ "no-triples-dataset": "This dataset has no triples",
+ "warning-aligned": "Have you aligned it with Freebase's schemas yet?",
+ "name-of-data": "Name of data load",
+ "source-id": "Source ID (optional)",
+ "bodytext-1": "Note: Your data will only be loaded into",
+ "bodytext-2": "Sandbox is where everyone can experiment with Freebase technologies without disruption to the official",
+ "bodytext-3": "Sandbox gets",
+ "sandbox-link": " Sandbox",
+ "freebase-link": " Freebase",
+ "refreshed-link": " refreshed periodically",
+ "bodytext-4": "In order to load your data into the official Freebase, you must first load it into Sandbox. Then it must pass a Quality Assurance (QA) process before it can be loaded into Freebase proper.",
+ "quality-assurance": "Quality assurance",
+ "bodytext-5": "After loaded into Sandbox, enlist other people's help to double-check this data load's quality so that it can be loaded into Freebase.",
+ "triple-schedule": "triples successfully scheduled for loading",
+ "follow-progress": "Follow the loading progress in the ",
+ "refinery-link": "Freebase Refinery",
+ "signed-as": "Signed in as:",
+ "sign-out": "Sign Out"
+ },
+ "fb-qa": {
+ "header": "QA Data Load?",
+ "bodytext-1": "Other people will be enlisted to help double-check your data load for quality assurance purposes. Their time and labor have a cost.",
+ "bodytext-2": "You yourself should have taken all reasonable measures to eliminate errors from your data load. Your prudence is greatly appreciated.",
+ "tell-more": "Tell me more ...",
+ "ok-button": "Yes, QA Data Load"
+ },
+ "fb-extend": {
+ "add-column": "Add Columns from Freebase Based on Column",
+ "warning-add-properties": "Please add some properties first.",
+ "querying-freebase": "Querying Freebase ...",
+ "remove-column": "Remove this column",
+ "add-constraints": "Add constraints to this column",
+ "mql-constraints": "Enter MQL query constraints as JSON",
+ "warning-valid-json": "Please ensure that the JSON you enter is valid.",
+ "warning-json-obj": "The JSON you enter must be an object, that is, it is of this form { ... }.",
+ "add-property": "Add Property",
+ "suggested-properties": "Suggested Properties",
+ "constraint": "Constraint"
+ },
+ "fb-buttons": {
+ "save": "Save",
+ "save-load": "Save & Load",
+ "close": "Close",
+ "reset": "Reset",
+ "cancel": "Cancel",
+ "align-now": "Align Now",
+ "settings": "Settings",
+ "preview": "Preview",
+ "load-sandbox": "Load to Sandbox",
+ "ok": "Ok"
+ }
+}
\ No newline at end of file
diff --git a/extensions/freebase/module/langs/translation-en.json b/extensions/freebase/module/langs/translation-en.json
new file mode 100644
index 000000000..2c9584b83
--- /dev/null
+++ b/extensions/freebase/module/langs/translation-en.json
@@ -0,0 +1,125 @@
+{
+ "fb-schema-alignment": {
+ "close-confirm": "There are unsaved changes. Close anyway?",
+ "status-warning": "There are unsaved changes.",
+ "assert-link-found": "Assert link when 'true' is found in column",
+ "search-pick-property": "Search for a property or pick one below",
+ "search-property": "Search for a property",
+ "cell": "cell",
+ "cells": "cells",
+ "which-column": "Which column?",
+ "configure": "Configure...",
+ "which-topic": "Which topic?",
+ "what-value": "What value?",
+ "anonymous": "anonymous",
+ "add-property": "add property",
+ "anonymous-node": "Anonymous Node",
+ "freebase-topic": "Freebase Topic",
+ "value": "Value",
+ "skeleton-node": "Schema Alignment Skeleton Node",
+ "text": "text",
+ "int": "int",
+ "float": "float",
+ "double": "double",
+ "boolean": "boolean",
+ "date-time": "date/time",
+ "rawstring": "rawstring",
+ "set-to-cell": "Set to Cell in Column",
+ "cell-content-used": "The cell's content is used ...",
+ "specify-fb-topic": "to specify a Freebase topic, as reconciled",
+ "type-new-topics": "Type new topics as",
+ "literal-value": "as a literal value",
+ "literal-type": "Literal type",
+ "text-language": "Text language",
+ "key-namespace": "as a key in a namespace",
+ "namespace": "Namespace",
+ "generate-anonymous": "Generate an anonymous graph node",
+ "assign-type": "Assign a type to the node",
+ "use-existing-topic": "Use one existing Freebase topic",
+ "value-type": "Value type",
+ "language": "Language",
+ "use-literal-value": "Use a literal value",
+ "column-warning": "You must select at least one column",
+ "new-node-warning": "For creating a new graph node, you need to specify a type for it.",
+ "namespace-warning": "Please specify the namespace.",
+ "anonymous-node-warning": "For generating an anonymous graph node, you need to specify a type for it.",
+ "specify-topic-warning": "Please specify which existing Freebase topic to use",
+ "specify-value-warning": "Please specify the value to use"
+ },
+ "fb-interface": {
+ "dialog-header": "Align to Freebase's Schemas",
+ "body-text": "The schema alignment skeleton below specifies how your grid-shaped data will be transformed into graph-shaped data in Freebase's schemas.",
+ "find-more": "Find out more ...",
+ "skeleton": "Skeleton",
+ "mql-preview": "MQL-like Preview",
+ "tripleloader-preview": "TripleLoader Preview"
+ },
+ "fb-dialogs": {
+ "sign-in": "Sign into Freebase",
+ "enable-loading": "to enable loading",
+ "error-new-topic": "Error creating new topic",
+ "error-loading-data": "Error loading data",
+ "add-info-source": "Click here to add a new information source",
+ "dialog-header": "Load Data into Freebase",
+ "no-triples-dataset": "This dataset has no triples",
+ "warning-aligned": "Have you aligned it with Freebase's schemas yet?",
+ "name-of-data": "Name of data load",
+ "source-id": "Source ID (optional)",
+ "bodytext-1": "Note: Your data will only be loaded into",
+ "bodytext-2": "Sandbox is where everyone can experiment with Freebase technologies without disruption to the official",
+ "bodytext-3": "Sandbox gets",
+ "sandbox-link": " Sandbox",
+ "freebase-link": " Freebase",
+ "refreshed-link": " refreshed periodically",
+ "bodytext-4": "In order to load your data into the official Freebase, you must first load it into Sandbox. Then it must pass a Quality Assurance (QA) process before it can be loaded into Freebase proper.",
+ "quality-assurance": "Quality assurance",
+ "bodytext-5": "After loaded into Sandbox, enlist other people's help to double-check this data load's quality so that it can be loaded into Freebase.",
+ "triple-schedule": "triples successfully scheduled for loading",
+ "follow-progress": "Follow the loading progress in the ",
+ "refinery-link": "Freebase Refinery",
+ "signed-as": "Signed in as:",
+ "sign-out": "Sign Out"
+ },
+ "fb-qa": {
+ "header": "QA Data Load?",
+ "bodytext-1": "Other people will be enlisted to help double-check your data load for quality assurance purposes. Their time and labor have a cost.",
+ "bodytext-2": "You yourself should have taken all reasonable measures to eliminate errors from your data load. Your prudence is greatly appreciated.",
+ "tell-more": "Tell me more ...",
+ "ok-button": "Yes, QA Data Load"
+ },
+ "fb-extend": {
+ "add-column": "Add Columns from Freebase Based on Column",
+ "warning-add-properties": "Please add some properties first.",
+ "querying-freebase": "Querying Freebase ...",
+ "remove-column": "Remove this column",
+ "add-constraints": "Add constraints to this column",
+ "mql-constraints": "Enter MQL query constraints as JSON",
+ "warning-valid-json": "Please ensure that the JSON you enter is valid.",
+ "warning-json-obj": "The JSON you enter must be an object, that is, it is of this form { ... }.",
+ "add-property": "Add Property",
+ "suggested-properties": "Suggested Properties",
+ "constraint": "Constraint"
+ },
+ "fb-menu": {
+ "freebase": "Freebase",
+ "set-api-key": "Set Freebase API Key",
+ "align-schema": "Align to Freebase's schemas...",
+ "load": "Load into Freebase...",
+ "browse-data-load": "Browse data load details...",
+ "import-qa": "Import QA data",
+ "add-columns": "Add columns from Freebase ...",
+ "warning-load": "You have not tried to load the data in this project into Freebase yet."
+ },
+ "fb-buttons": {
+ "save": "Save",
+ "save-load": "Save & Load",
+ "close": "Close",
+ "reset": "Reset",
+ "cancel": "Cancel",
+ "align-now": "Align Now",
+ "settings": "Settings",
+ "preview": "Preview",
+ "load-sandbox": "Load to Sandbox",
+ "ok": "Ok"
+ }
+}
\ No newline at end of file
diff --git a/extensions/freebase/module/langs/translation-it.json b/extensions/freebase/module/langs/translation-it.json
new file mode 100644
index 000000000..dfc7aa1b3
--- /dev/null
+++ b/extensions/freebase/module/langs/translation-it.json
@@ -0,0 +1,125 @@
+{
+ "fb-schema-alignment": {
+ "close-confirm": "Ci sono cambiamenti non salvati. Chiudere comunque?",
+ "status-warning": "Ci sono cambiamenti non salvati.",
+ "assert-link-found": "Assert link when 'true' is found in column",
+ "search-pick-property": "Cerca una proprietà o scegline una dalle seguenti",
+ "search-property": "Cerca una proprietà",
+ "cell": "cella",
+ "cells": "celle",
+ "which-column": "Quale colonna?",
+ "configure": "Configura...",
+ "which-topic": "Quale topic?",
+ "what-value": "Quale valore?",
+ "anonymous": "anonimo",
+ "add-property": "aggiungi proprietà",
+ "anonymous-node": "Nodo Anonimo",
+ "freebase-topic": "Topic Freebase",
+ "value": "Valore",
+ "skeleton-node": "Schema Alignment Skeleton Node",
+ "text": "testo",
+ "int": "int",
+ "float": "float",
+ "double": "double",
+ "boolean": "boolean",
+ "date-time": "data/ora",
+ "rawstring": "rawstring",
+ "set-to-cell": "Set to Cell in Column",
+ "cell-content-used": "Il contenuto della cella è usato ...",
+ "specify-fb-topic": "per specificare un topic Freebase, come riconciliato",
+ "type-new-topics": "Inserisci il nuovo topic come",
+ "literal-value": "come un valore letterale",
+ "literal-type": "Tipo letterale",
+ "text-language": "Lingua di testo",
+ "key-namespace": "come una chiave nel namespace",
+ "namespace": "Namespace",
+ "generate-anonymous": "Genera un nodo anonimo nel grafo",
+ "assign-type": "Assegna un tipo al nodo",
+ "use-existing-topic": "Usa un topic Freebase esistente",
+ "value-type": "Tipo valore",
+ "language": "Lingua",
+ "use-literal-value": "Usa un valore letterale",
+ "column-warning": "Devi selezionare almeno una colonna",
+ "new-node-warning": "Per creare un nuovo nodo nel grafo, devi specificarne un tipo.",
+ "namespace-warning": "Specifica il namespace.",
+ "anonymous-node-warning": "Per generare un nodo anonimo nel grafo, devi specificarne un tipo.",
+ "specify-topic-warning": "Per favore specifica quale topic esistente di Freebase usare",
+ "specify-value-warning": "Per favore specifica il valore da usare"
+ },
+ "fb-interface": {
+ "dialog-header": "Allinea con gli schemi Freebase",
+ "body-text": "Lo scheletro per l'allineamento della schema specifica come i tuoi dati in formato tabellare saranno trasformati in un formato a grafo con lo schema di Freebase.",
+ "find-more": "Per saperne di più ...",
+ "skeleton": "Scheletro",
+ "mql-preview": "Anteprima MQL-like",
+ "tripleloader-preview": "Anteprima TripleLoader"
+ },
+ "fb-dialogs": {
+ "sign-in": "Accedi a Freebase",
+ "enable-loading": "per abilitare il caricamento",
+ "error-new-topic": "Errore nella creazione di un nuovo topic",
+ "error-loading-data": "Errore durante il caricamento dei dati",
+ "add-info-source": "Clicca qui per aggiungere una nuova sorgente di informazioni",
+ "dialog-header": "Carica i dati in Freebase",
+ "no-triples-dataset": "Questo dataset non ha triple",
+ "warning-aligned": "Hai già effettuato l'allineamento con lo schema Freebase?",
+ "name-of-data": "Nome del caricamento dati",
+ "source-id": "ID sorgente (opzionale)",
+ "bodytext-1": "Nota: i tuoi dati saranno caricati solamente in",
+ "bodytext-2": "Sandbox è dove chiunque può sperimentare le tecnologie Freebase senza creare danni all'ufficiale",
+ "bodytext-3": "Sandbox viene",
+ "sandbox-link": " Sandbox",
+ "freebase-link": " Freebase",
+ "refreshed-link": " aggiornata periodicamente",
+ "bodytext-4": "Per caricare i tuoi data su Freebase ufficiale, devi prima caricarli nel Sandbox. Successivamente, devono passare un processo di analisi qualitativa prima di essere caricati su Freebase.",
+ "quality-assurance": "Analisi qualitativa",
+ "bodytext-5": "Dopo essere caricati nella Sandbox, viene chiesto l'aiuto di altre persone per controllare due volte la qualità di questi dati in modo da poter poi essere caricati in Freebase.",
+ "triple-schedule": "triple pianificate con successo per il caricamento",
+ "follow-progress": "Segui il processo di caricamento nel ",
+ "refinery-link": "Freebase Refinery",
+ "signed-as": "Accesso effettuato come:",
+ "sign-out": "Esci"
+ },
+ "fb-qa": {
+ "header": "Caricamento dati con analisi qualitativa?",
+ "bodytext-1": "Alcune persone verranno incaricate per controllare i tuoi dati allo scopo di verificarne la qualità. Il loro tempo e lavoro ha un costo.",
+ "bodytext-2": "Tu stesso dovresti aver già effettuato la maggior parte dei controlli per assicurarti di aver rimosso errori dai dati. La tua prudenza è enormemente apprezzata.",
+ "tell-more": "Dimmi di più ...",
+ "ok-button": "Si, Caricamento dati con analisi qualitativa"
+ },
+ "fb-extend": {
+ "add-column": "Aggiungi colonne da Freebase basandoti sulla colonna",
+ "warning-add-properties": "Prima aggiungi delle proprietà.",
+ "querying-freebase": "Interrogando Freebase ...",
+ "remove-column": "Rimuovi questa colonna",
+ "add-constraints": "Aggiungi vincoli a questa colonna",
+ "mql-constraints": "Inserisci i vincoli per la query MQL come JSON",
+ "warning-valid-json": "Assicurati che l'oggetto JSON inserito sia valido.",
+ "warning-json-obj": "Il JSON che inserisci deve essere un oggetto, cioè in questa forma: { ... }.",
+ "add-property": "Aggiungi Proprietà",
+ "suggested-properties": "Proprietà suggerite",
+ "constraint": "Vincoli"
+ },
+ "fb-menu": {
+ "freebase": "Freebase",
+ "set-api-key": "Imposta l'API Key Freebase",
+ "align-schema": "Allinea con lo schema Freebase...",
+ "load": "Carica in Freebase...",
+ "browse-data-load": "Vedi i dettagli per il caricamento dati...",
+ "import-qa": "Importa dati con controllo qualità",
+ "add-columns": "Aggiungi colonne da Freebase ...",
+ "warning-load": "Non hai ancora provato a caricare i dati di questo progetto in Freebase."
+ },
+ "fb-buttons": {
+ "save": "Salva",
+ "save-load": "Salva & Carica",
+ "close": "Chiudi",
+ "reset": "Reset",
+ "cancel": "Cancella",
+ "align-now": "Allinea adesso",
+ "settings": "Settings",
+ "preview": "Anteprima",
+ "load-sandbox": "Carica nella Sandbox",
+ "ok": "Ok"
+ }
+}
\ No newline at end of file
diff --git a/extensions/freebase/module/scripts/dialogs/confirm-qa-dialog.html b/extensions/freebase/module/scripts/dialogs/confirm-qa-dialog.html
index d691dee41..e5ce6d108 100644
--- a/extensions/freebase/module/scripts/dialogs/confirm-qa-dialog.html
+++ b/extensions/freebase/module/scripts/dialogs/confirm-qa-dialog.html
@@ -1,17 +1,12 @@
-
QA Data Load?
+
-
Other people will be enlisted to help double-check
- your data load for quality assurance purposes. Their time and labor
- have a cost.
-
-
You yourself should have taken all reasonable measures
- to eliminate errors from your data load. Your prudence is greatly appreciated.
-
\ No newline at end of file
diff --git a/extensions/freebase/module/scripts/dialogs/extend-data-preview-dialog.html b/extensions/freebase/module/scripts/dialogs/extend-data-preview-dialog.html
index f92e09fb9..6db8cb87c 100644
--- a/extensions/freebase/module/scripts/dialogs/extend-data-preview-dialog.html
+++ b/extensions/freebase/module/scripts/dialogs/extend-data-preview-dialog.html
@@ -3,16 +3,16 @@
-
Add Property
+
Preview
-
+
-
Suggested Properties
+
@@ -20,7 +20,7 @@
\ No newline at end of file
diff --git a/extensions/freebase/module/scripts/dialogs/extend-data-preview-dialog.js b/extensions/freebase/module/scripts/dialogs/extend-data-preview-dialog.js
index 2ed89a01c..fafaca07c 100644
--- a/extensions/freebase/module/scripts/dialogs/extend-data-preview-dialog.js
+++ b/extensions/freebase/module/scripts/dialogs/extend-data-preview-dialog.js
@@ -41,15 +41,23 @@ function ExtendDataPreviewDialog(column, columnIndex, rowIndices, onDone) {
var self = this;
this._dialog = $(DOM.loadHTML("freebase", "scripts/dialogs/extend-data-preview-dialog.html"));
this._elmts = DOM.bind(this._dialog);
- this._elmts.dialogHeader.text("Add Columns from Freebase Based on Column " + column.name);
+
+ this._elmts.dialogHeader.text($.i18n._('fb-extend')["add-column"]);
+ this._elmts.fb_add_property.html($.i18n._('fb-extend')["add-property"]);
+ this._elmts.suggested_properties.text($.i18n._('fb-extend')["suggested-properties"]);
+
+ this._elmts.resetButton.text($.i18n._('fb-buttons')["reset"]);
+ this._elmts.okButton.html(' '+$.i18n._('fb-buttons')["ok"]+' ');
+ this._elmts.cancelButton.text($.i18n._('fb-buttons')["cancel"]);
+
this._elmts.resetButton.click(function() {
self._extension.properties = [];
self._update();
});
-
+
this._elmts.okButton.click(function() {
if (self._extension.properties.length === 0) {
- alert("Please add some properties first.");
+ alert($.i18n._('fb-extend')["warning-add-properties"]);
} else {
DialogSystem.dismissUntil(self._level - 1);
self._onDone(self._extension);
@@ -157,7 +165,7 @@ ExtendDataPreviewDialog.prototype._show = function(properties) {
};
ExtendDataPreviewDialog.prototype._update = function() {
- this._elmts.previewContainer.empty().text("Querying Freebase ...");
+ this._elmts.previewContainer.empty().text($.i18n._('fb-extend')["querying-freebase"]);
var self = this;
var params = {
@@ -234,7 +242,7 @@ ExtendDataPreviewDialog.prototype._renderPreview = function(data) {
$('')
.text("remove")
.addClass("action")
- .attr("title", "Remove this column")
+ .attr("title", $.i18n._('fb-extend')["remove-column"])
.click(function() {
self._removeProperty(column.path);
}).appendTo(th);
@@ -242,7 +250,7 @@ ExtendDataPreviewDialog.prototype._renderPreview = function(data) {
$('')
.text("constrain")
.addClass("action")
- .attr("title", "Add constraints to this column")
+ .attr("title", $.i18n._('fb-extend')["add-constraints"])
.click(function() {
self._constrainProperty(column.path);
}).appendTo(th);
@@ -329,14 +337,14 @@ ExtendDataPreviewDialog.prototype._constrainProperty = function(path) {
var frame = DialogSystem.createDialog();
frame.width("500px");
- var header = $('').addClass("dialog-header").text("Constrain " + path.join(" > ")).appendTo(frame);
+ var header = $('').addClass("dialog-header").text(" " + path.join(" > ")).appendTo(frame);
var body = $('').addClass("dialog-body").appendTo(frame);
var footer = $('').addClass("dialog-footer").appendTo(frame);
body.html(
'
' +
'' +
@@ -352,8 +360,8 @@ ExtendDataPreviewDialog.prototype._constrainProperty = function(path) {
}
footer.html(
- '' +
- ''
+ '' +
+ ''
);
var footerElmts = DOM.bind(footer);
@@ -367,7 +375,7 @@ ExtendDataPreviewDialog.prototype._constrainProperty = function(path) {
try {
var o = JSON.parse(bodyElmts.textarea[0].value);
if (o === undefined) {
- alert("Please ensure that the JSON you enter is valid.");
+ alert($.i18n._('fb-extend')["warning-valid-json"]);
return;
}
@@ -375,7 +383,7 @@ ExtendDataPreviewDialog.prototype._constrainProperty = function(path) {
o = o[0];
}
if (!$.isPlainObject(o)) {
- alert("The JSON you enter must be an object, that is, it is of this form { ... }.");
+ alert($.i18n._('fb-extend')["warning-json-obj"]);
return;
}
diff --git a/extensions/freebase/module/scripts/dialogs/freebase-loading-dialog.html b/extensions/freebase/module/scripts/dialogs/freebase-loading-dialog.html
index 0eb1d1033..c478b4441 100644
--- a/extensions/freebase/module/scripts/dialogs/freebase-loading-dialog.html
+++ b/extensions/freebase/module/scripts/dialogs/freebase-loading-dialog.html
@@ -1,44 +1,40 @@
Note: Your data will only be loaded into
- Sandbox.
- Sandbox is where everyone can experiment with Freebase technologies without disruption
- to the official Freebase. Sandbox gets
- refreshed periodically.
+
+ .
+ .
+ .
-
In order to load your data into the official Freebase, you must first load it
- into Sandbox. Then it must pass a Quality Assurance (QA) process before it can
- be loaded into Freebase proper.
- Find out more ...
+
+
-
Quality assurance
+
-
After loaded into Sandbox, enlist other people's help to double-check
- this data load's quality so that it can be loaded into Freebase.
-
\ No newline at end of file
diff --git a/extensions/freebase/module/scripts/dialogs/freebase-loading-dialog.js b/extensions/freebase/module/scripts/dialogs/freebase-loading-dialog.js
index c6c230eda..d7e43744a 100644
--- a/extensions/freebase/module/scripts/dialogs/freebase-loading-dialog.js
+++ b/extensions/freebase/module/scripts/dialogs/freebase-loading-dialog.js
@@ -45,13 +45,37 @@ FreebaseLoadingDialog.prototype._createDialog = function() {
var provider = "freebase.com";
var authorization = this._elmts.authorization;
var loadButton = this._elmts.loadButton;
-
+
+ this._elmts.dialogHeader.text($.i18n._('fb-dialogs')["dialog-header"]);
+ this._elmts.no_triples_dataset.text($.i18n._('fb-dialogs')["no-triples-dataset"]);
+ this._elmts.warning_aligned.text($.i18n._('fb-dialogs')["warning-aligned"]);
+ this._elmts.alignButton.text($.i18n._('fb-buttons')["align-now"]);
+ this._elmts.settingsBtn.text($.i18n._('fb-buttons')["settings"]);
+ this._elmts.previewBtn.text($.i18n._('fb-buttons')["preview"]);
+ this._elmts.name_of_data.text($.i18n._('fb-dialogs')["name-of-data"]);
+ this._elmts.source_id_label.text($.i18n._('fb-dialogs')["source-id"]);
+ this._elmts.bodytext1.text($.i18n._('fb-dialogs')["bodytext-1"]);
+ this._elmts.bodytext2.text($.i18n._('fb-dialogs')["bodytext-2"]);
+ this._elmts.bodytext3.text($.i18n._('fb-dialogs')["bodytext-3"]);
+ this._elmts.sandbox_link.text($.i18n._('fb-dialogs')["sandbox-link"]);
+ this._elmts.freebase_link.text($.i18n._('fb-dialogs')["freebase-link"]);
+ this._elmts.refreshed_link.text($.i18n._('fb-dialogs')["refreshed-link"]);
+ this._elmts.bodytext4.text($.i18n._('fb-dialogs')["bodytext-4"]);
+ this._elmts.findOutMore.text($.i18n._('fb-interface')["find-more"]);
+ this._elmts.quality_assurance.text($.i18n._('fb-dialogs')["quality-assurance"]);
+ this._elmts.bodytext5.text($.i18n._('fb-dialogs')["bodytext-5"]);
+ this._elmts.triple_success_load.text($.i18n._('fb-dialogs')["triple-schedule"]);
+ this._elmts.follow_progress.text($.i18n._('fb-dialogs')["follow-progress"]);
+ this._elmts.refineryLink.text($.i18n._('fb-dialogs')["refinery-link"]);
+ this._elmts.cancelButton.text($.i18n._('fb-buttons')["cancel"]);
+ this._elmts.loadButton.text($.i18n._('fb-buttons')["load-sandbox"]);
+
// TODO: Does this need to be redone for the new API / freebase.com site?
var check_authorization = function(cont) {
var check_authorization_url = "command/freebase/check-authorization/" + provider;
$.get(check_authorization_url, function(data) {
if ("status" in data && data.code == "/api/status/ok") {
- authorization.html('Signed in as: ' + data.username + ' | Sign Out').show();
+ authorization.html($.i18n._('fb-dialogs')["signed-as"]+' ' + data.username + ' | '+$.i18n._('fb-dialogs')["sign-out"]+'').show();
DOM.bind(authorization).signout.click(function() {
self._signedin = false;
loadButton.attr("disabled","disabled");
@@ -71,7 +95,7 @@ FreebaseLoadingDialog.prototype._createDialog = function() {
if (typeof cont == "function") cont(data);
} else {
- authorization.html('Sign into Freebase to enable loading').show();
+ authorization.html(''+$.i18n._('fb-dialogs')["sign-in"]+' '+$.i18n._('fb-dialogs')["enable-loading"]).show();
self._signedin = false;
$("#freebase-loading-source-name").keyup();
@@ -104,7 +128,7 @@ FreebaseLoadingDialog.prototype._createDialog = function() {
self._elmts.source_id.val(data.result[0].id);
if (typeof cont == "function") cont();
} else {
- self._show_error("Error creating new topic", data);
+ self._show_error($.i18n._('fb-dialogs')["error-new-topic"], data);
}
},
"json"
@@ -137,7 +161,7 @@ FreebaseLoadingDialog.prototype._createDialog = function() {
self._elmts.source_id.suggest({
filter: "(all type:/dataworld/information_source)",
- suggest_new: "Click here to add a new information source"
+ suggest_new: $.i18n._('fb-dialogs')["add-info-source"]
}).bind("fb-select", function(e, data) {
self._elmts.source_id.val(data.id);
}).bind("fb-select-new", function(e, val) {
@@ -202,7 +226,7 @@ FreebaseLoadingDialog.prototype._load = function() {
self._elmts.loadedCase.show();
self._end();
} else {
- self._show_error("Error loading data",data);
+ self._show_error($.i18n._('fb-dialogs')["error-loading-data"],data);
}
},
"json"
@@ -216,6 +240,13 @@ FreebaseLoadingDialog.prototype._load = function() {
var dismiss = function() {
DialogSystem.dismissUntil(level - 1);
};
+
+ this._elmts.refineryLink.text($.i18n._('fb-qa')["header"]);
+ this._elmts.bodytext1.text($.i18n._('fb-qa')["bodytext-1"]);
+ this._elmts.bodytext2.text($.i18n._('fb-qa')["bodytext-2"]);
+ this._elmts.tellMore.text($.i18n._('fb-qa')["tell-more"]);
+ this._elmts.okButton.text($.i18n._('fb-qa')["ok-button"]);
+ this._elmts.cancelButton.text($.i18n._('fb-qa')["ok-button"]);
elmts.okButton.click(function() {
doLoad();
diff --git a/extensions/freebase/module/scripts/dialogs/schema-alignment/dialog.js b/extensions/freebase/module/scripts/dialogs/schema-alignment/dialog.js
index 8dfeced1e..922b45c15 100644
--- a/extensions/freebase/module/scripts/dialogs/schema-alignment/dialog.js
+++ b/extensions/freebase/module/scripts/dialogs/schema-alignment/dialog.js
@@ -234,6 +234,17 @@ SchemaAlignmentDialog.prototype._createDialog = function() {
DialogSystem.dismissUntil(self._level - 1);
};
+ elmts.dialogHeader.text($.i18n._('fb-interface')["dialog-header"]);
+ elmts.body_text.text($.i18n._('fb-interface')["body-text"]);
+ elmts.find_more.text($.i18n._('fb-interface')["find-more"]);
+ elmts.skeleton.text($.i18n._('fb-interface')["skeleton"]);
+ elmts.skeleton.text($.i18n._('fb-interface')["mql-preview"]);
+ elmts.skeleton.text($.i18n._('fb-interface')["tripleloader-preview"]);
+ elmts.saveButton.text($.i18n._('fb-buttons')["save"]);
+ elmts.saveAndLoadButton.text($.i18n._('fb-buttons')["save-load"]);
+ elmts.closeButton.text($.i18n._('fb-buttons')["close"]);
+ elmts.resetButton.text($.i18n._('fb-buttons')["reset"]);
+
elmts.saveButton.click(function() {
self._save();
});
@@ -247,7 +258,7 @@ SchemaAlignmentDialog.prototype._createDialog = function() {
self._reset(null);
});
elmts.closeButton.click(function() {
- if (!self._hasUnsavedChanges || window.confirm("There are unsaved changes. Close anyway?")) {
+ if (!self._hasUnsavedChanges || window.confirm($.i18n._('fb-schema-alignment')["close-confirm"])) {
dismiss();
}
});
@@ -281,7 +292,7 @@ SchemaAlignmentDialog.prototype.preview = function(initial) {
this._previewPanes.empty();
if (!(initial)) {
- this._elmts.statusIndicator.show().text("There are unsaved changes.");
+ this._elmts.statusIndicator.show().text($.i18n._('fb-schema-alignment')["status-warning"]);
this._hasUnsavedChanges = true;
}
diff --git a/extensions/freebase/module/scripts/dialogs/schema-alignment/schema-alignment-dialog.html b/extensions/freebase/module/scripts/dialogs/schema-alignment/schema-alignment-dialog.html
index 6315ed1b9..bd6750e2e 100644
--- a/extensions/freebase/module/scripts/dialogs/schema-alignment/schema-alignment-dialog.html
+++ b/extensions/freebase/module/scripts/dialogs/schema-alignment/schema-alignment-dialog.html
@@ -1,16 +1,14 @@
-
Align to Freebase's Schemas
+
-
- The schema alignment skeleton below specifies how your grid-shaped data will be
- transformed into graph-shaped data in Freebase's schemas.
- Find out more ...
+
\ No newline at end of file
diff --git a/extensions/freebase/module/scripts/dialogs/schema-alignment/ui-link.js b/extensions/freebase/module/scripts/dialogs/schema-alignment/ui-link.js
index bf71e4e2b..07e112f8c 100644
--- a/extensions/freebase/module/scripts/dialogs/schema-alignment/ui-link.js
+++ b/extensions/freebase/module/scripts/dialogs/schema-alignment/ui-link.js
@@ -239,7 +239,7 @@ SchemaAlignmentDialog.UILink.prototype._showPropertySuggestPopup = function(elmt
var divConditional = $('
')
.addClass("schema-alignment-link-menu-section")
- .html("Assert link when 'true' is found in column ").appendTo(menu);
+ .html($.i18n._('fb-schema-alignment')["assert-link-found"]+" ").appendTo(menu);
var conditionalSelect = $('
Create a project by importing data. What kinds of data files can I import?
-
TSV, CSV, *SV, Excel (.xls and .xlsx), JSON, XML, RDF as XML, and
- Google Data documents are all supported. Support for other formats can
- be added with OpenRefine extensions.
-
- Click on the first JSON { } node corresponding to the first record to load.
-
+
\ No newline at end of file
diff --git a/main/webapp/modules/core/scripts/index/parser-interfaces/json-parser-ui.html b/main/webapp/modules/core/scripts/index/parser-interfaces/json-parser-ui.html
index 0572216f9..5f00d98ac 100644
--- a/main/webapp/modules/core/scripts/index/parser-interfaces/json-parser-ui.html
+++ b/main/webapp/modules/core/scripts/index/parser-interfaces/json-parser-ui.html
@@ -3,25 +3,25 @@
- Click on the first XML element corresponding to the first record to load.
+
\ No newline at end of file
diff --git a/main/webapp/modules/core/scripts/index/parser-interfaces/xml-parser-ui.html b/main/webapp/modules/core/scripts/index/parser-interfaces/xml-parser-ui.html
index 3aff4f11b..f441246ee 100644
--- a/main/webapp/modules/core/scripts/index/parser-interfaces/xml-parser-ui.html
+++ b/main/webapp/modules/core/scripts/index/parser-interfaces/xml-parser-ui.html
@@ -3,26 +3,26 @@
- Extract and save parts of your operation history as JSON that you can apply to this or other projects in the future.
+
+
@@ -16,14 +16,14 @@
- Select All
- Unselect All
+
+
\ No newline at end of file
diff --git a/main/webapp/modules/core/scripts/project/history-panel.html b/main/webapp/modules/core/scripts/project/history-panel.html
index 8f0b6b8e3..ea10e168c 100644
--- a/main/webapp/modules/core/scripts/project/history-panel.html
+++ b/main/webapp/modules/core/scripts/project/history-panel.html
@@ -1,13 +1,13 @@
-
Infinite undo history
-
Don't worry about making mistakes. Every change you make will be shown here, and you can undo your changes anytime.
\ No newline at end of file
diff --git a/main/webapp/modules/core/scripts/project/summary-bar.js b/main/webapp/modules/core/scripts/project/summary-bar.js
index 46ad04879..4a804cf3e 100644
--- a/main/webapp/modules/core/scripts/project/summary-bar.js
+++ b/main/webapp/modules/core/scripts/project/summary-bar.js
@@ -42,7 +42,7 @@ SummaryBar.prototype._initializeUI = function() {
SummaryBar.prototype.updateResultCount = function() {
var summaryText;
- var units = theProject.rowModel.mode == "row-based" ? "rows" : "records";
+ var units = theProject.rowModel.mode == "row-based" ? $.i18n._('core-views')["rows"] : $.i18n._('core-views')["records"];
if (theProject.rowModel.filtered == theProject.rowModel.total) {
summaryText = (theProject.rowModel.total) + ' ' + units;
} else {
diff --git a/main/webapp/modules/core/scripts/reconciliation/add-namespaced-service-dialog.html b/main/webapp/modules/core/scripts/reconciliation/add-namespaced-service-dialog.html
index 032e6644c..f055cedaa 100644
--- a/main/webapp/modules/core/scripts/reconciliation/add-namespaced-service-dialog.html
+++ b/main/webapp/modules/core/scripts/reconciliation/add-namespaced-service-dialog.html
@@ -1,13 +1,13 @@
-
Add Namespaced Reconciliation Service
+
-
Namespace:
+
-
Type of Entities (optional):
+
\ No newline at end of file
diff --git a/main/webapp/modules/core/scripts/reconciliation/add-standard-service-dialog.html b/main/webapp/modules/core/scripts/reconciliation/add-standard-service-dialog.html
index 0a28ce775..f1e923a57 100644
--- a/main/webapp/modules/core/scripts/reconciliation/add-standard-service-dialog.html
+++ b/main/webapp/modules/core/scripts/reconciliation/add-standard-service-dialog.html
@@ -1,11 +1,11 @@
-
Add Standard Reconciliation Service
+
-
Enter the service's URL:
+
\ No newline at end of file
diff --git a/main/webapp/modules/core/scripts/reconciliation/freebase-query-panel.html b/main/webapp/modules/core/scripts/reconciliation/freebase-query-panel.html
index b67ace285..99b9213bb 100644
--- a/main/webapp/modules/core/scripts/reconciliation/freebase-query-panel.html
+++ b/main/webapp/modules/core/scripts/reconciliation/freebase-query-panel.html
@@ -1,20 +1,20 @@
-
Each cell contains:
+
-
a Freebase ID, e.g., /en/solar_system
-
a Freebase GUID, e.g., #9202a8c04000641f80000000000354ae