Inject service in file-preview component
This commit is contained in:
parent
355cb3a4d3
commit
cd8d32d812
@ -1,9 +1,10 @@
|
|||||||
import Component from '@ember/component';
|
import Component from '@ember/component';
|
||||||
|
import { inject as service } from '@ember/service';
|
||||||
import { alias } from '@ember/object/computed';
|
import { alias } from '@ember/object/computed';
|
||||||
|
|
||||||
export default Component.extend({
|
export default Component.extend({
|
||||||
|
|
||||||
storage: null,
|
storage: service(),
|
||||||
|
|
||||||
classNames: ['file-preview'],
|
classNames: ['file-preview'],
|
||||||
|
|
||||||
@ -11,6 +12,7 @@ export default Component.extend({
|
|||||||
fileContent: null,
|
fileContent: null,
|
||||||
objectURL: null,
|
objectURL: null,
|
||||||
metaData: null,
|
metaData: null,
|
||||||
|
jsonView: null,
|
||||||
type: alias('metaData.type'),
|
type: alias('metaData.type'),
|
||||||
isBinary: alias('metaData.isBinary'),
|
isBinary: alias('metaData.isBinary'),
|
||||||
|
|
||||||
|
@ -14,7 +14,10 @@
|
|||||||
<div class="inspect-details">
|
<div class="inspect-details">
|
||||||
<section class="content">
|
<section class="content">
|
||||||
{{file-preview metaData=model.documentMetaData
|
{{file-preview metaData=model.documentMetaData
|
||||||
storage=storage}}
|
documentIsJSON=documentIsJSON
|
||||||
|
jsonView=jsonView
|
||||||
|
showJsonTree=showJsonTree
|
||||||
|
showJsonSource=showJsonSource}}
|
||||||
</section>
|
</section>
|
||||||
<section class="meta">
|
<section class="meta">
|
||||||
<dl>
|
<dl>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user