summaryrefslogtreecommitdiffstats
path: root/install/ui/src/freeipa/text.js
diff options
context:
space:
mode:
authorPetr Vobornik <pvoborni@redhat.com>2013-04-03 15:12:42 +0200
committerPetr Vobornik <pvoborni@redhat.com>2013-05-06 16:22:21 +0200
commit13e34216eb8b2015042b1fcc6af5efd7cd962c58 (patch)
treed470f23a4024ba5256edadffe6a9f0f8b670381c /install/ui/src/freeipa/text.js
parent1b90b3b65ea214a3a09922f6b9c1de304e5257da (diff)
downloadfreeipa-13e34216eb8b2015042b1fcc6af5efd7cd962c58.tar.gz
freeipa-13e34216eb8b2015042b1fcc6af5efd7cd962c58.tar.xz
freeipa-13e34216eb8b2015042b1fcc6af5efd7cd962c58.zip
Metadata and text providers
https://fedorahosted.org/freeipa/ticket/3235
Diffstat (limited to 'install/ui/src/freeipa/text.js')
-rw-r--r--install/ui/src/freeipa/text.js40
1 files changed, 40 insertions, 0 deletions
diff --git a/install/ui/src/freeipa/text.js b/install/ui/src/freeipa/text.js
new file mode 100644
index 000000000..1e5b0e591
--- /dev/null
+++ b/install/ui/src/freeipa/text.js
@@ -0,0 +1,40 @@
+/* Authors:
+ * Petr Vobornik <pvoborni@redhat.com>
+ *
+ * Copyright (C) 2013 Red Hat
+ * see file 'COPYING' for use and warranty information
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+/**
+ * Text provider
+ *
+ * Serves for returning labels, titles, messages from various providers.
+ * Other providers can extends functionality.
+ */
+define(['./_base/Provider', './_base/i18n', './_base/metadata_provider'],
+ function(Provider, i18n, metadata) {
+
+ var text = new Provider({
+ providers: [
+ i18n,
+ metadata
+ ],
+ null_value: '',
+ required_type: 'string'
+ });
+
+ return text;
+}); \ No newline at end of file