--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/common/corpus-common-addon/addon/components/doc-olac.js Thu Jan 19 13:53:17 2017 +0100
@@ -0,0 +1,20 @@
+import Ember from 'ember';
+import layout from '../templates/components/doc-olac';
+import DocLiteral from './doc-literal';
+import * as utils from 'corpus-common-addon/utils/utils';
+
+export default DocLiteral.extend({
+ layout,
+ olacUrl: Ember.computed('url', function () {
+ const url = this.get('url');
+ const value = this.get('value');
+
+ const olacDef = utils.getOLACBaseUrl(url);
+
+ if (!olacDef) {
+ return '';
+ }
+
+ return olacDef.baseUrl + value;
+ })
+});