mirror of
https://github.com/documize/community.git
synced 2025-07-31 11:09:42 +02:00
Document meta fields: better popovers & click-through editing
Non-admins receive popovers on hover. Admins receive no popovers and get click-through to settings tab. Space and document settings support jump to sub-section. Co-Authored-By: Harvey Kandola <harvey@documize.com>
This commit is contained in:
parent
5d80480d75
commit
ad44112359
6 changed files with 65 additions and 34 deletions
|
@ -1,28 +1,28 @@
|
|||
{{#if (eq document.lifecycle constants.Lifecycle.Live)}}
|
||||
<div id="document-lifecycle-popover" class="document-lifecycle-live text-uppercase">{{document.lifecycleLabel}}</div>
|
||||
<div id="document-lifecycle-popover" class="document-lifecycle-live text-uppercase" {{action 'onEditLifecycle'}}>{{document.lifecycleLabel}}</div>
|
||||
{{/if}}
|
||||
{{#if (eq document.lifecycle constants.Lifecycle.Draft)}}
|
||||
<div id="document-lifecycle-popover" class="document-lifecycle-draft text-uppercase">{{document.lifecycleLabel}}</div>
|
||||
<div id="document-lifecycle-popover" class="document-lifecycle-draft text-uppercase" {{action 'onEditLifecycle'}}>{{document.lifecycleLabel}}</div>
|
||||
{{/if}}
|
||||
|
||||
<div class="d-block d-sm-none margin-top-20" />
|
||||
<div class="d-sm-inline-block margin-left-20" />
|
||||
|
||||
{{#if (eq document.protection constants.ProtectionType.None)}}
|
||||
<div id="document-protection-popover" class="document-protection-unlocked text-uppercase">OPEN</div>
|
||||
<div id="document-protection-popover" class="document-protection-unlocked text-uppercase" {{action 'onEditProtection'}}>OPEN</div>
|
||||
{{/if}}
|
||||
{{#if (eq document.protection constants.ProtectionType.Review)}}
|
||||
<div id="document-protection-popover" class="document-protection-review text-uppercase">PROTECTED</div>
|
||||
<div id="document-protection-popover" class="document-protection-review text-uppercase" {{action 'onEditProtection'}}>PROTECTED</div>
|
||||
{{/if}}
|
||||
{{#if (eq document.protection constants.ProtectionType.Lock)}}
|
||||
<div id="document-protection-popover" class="document-protection-locked text-uppercase">LOCKED</div>
|
||||
<div id="document-protection-popover" class="document-protection-locked text-uppercase" {{action 'onEditProtection'}}>LOCKED</div>
|
||||
{{/if}}
|
||||
|
||||
<div class="d-block d-sm-none margin-top-20" />
|
||||
<div class="d-sm-inline-block margin-left-20" />
|
||||
|
||||
{{#each selectedCategories as |cat|}}
|
||||
<div class="document-category" data-toggle="tooltip" data-placement="top" title="Category">
|
||||
<div class="document-category {{if isSpaceAdmin 'cursor-pointer'}}" data-toggle="tooltip" data-placement="top" title="Category">
|
||||
{{cat.category}}
|
||||
</div>
|
||||
{{/each}}
|
||||
|
@ -30,13 +30,13 @@
|
|||
<div class="d-block d-sm-none margin-top-20" />
|
||||
|
||||
{{#each tagz as |t index|}}
|
||||
<div class="document-tag" data-toggle="tooltip" data-placement="top" title="Tag">
|
||||
<div class="document-tag {{if isSpaceAdmin 'cursor-pointer'}}" data-toggle="tooltip" data-placement="top" title="Tag" {{action 'onEditCategory'}}>
|
||||
{{concat '#' t}}
|
||||
</div>
|
||||
{{/each}}
|
||||
|
||||
<div class="document-meta">
|
||||
{{document/view-attachment document=document permissions=permissions}}
|
||||
{{document/view-attachment document=document permissions=permissions {{action 'onEditCategory'}}}}
|
||||
</div>
|
||||
|
||||
<div class="margin-top-70" />
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue