-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy patheditable.html
88 lines (81 loc) · 3.11 KB
/
editable.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
<template name="m_editable">
{{#with settings}}
{{> m_editable_main}}
{{/with}}
</template>
<template name="m_editable_handle_atag">
<a href="#" class="editable editable-click {{editableEmpty}} {{extraClasses}}">{{displayVal}}</a>
</template>
<template name="m_editable_handle_disabled">
<span>{{displayVal}}</span>
</template>
<template name="m_editable_popover">
<div class="popover {{position}} editable-popup m_editable-popup editable-container">
<div class="arrow"></div>
{{#if title}}
<h3 class="popover-title">{{title}}</h3>
{{/if}}
<div class="popover-content">
{{#unless loading}}
<div>
<div class="editableform-loading" style="display: none;"><span class="editableform-loading"></span></div>
<form class="form-inline editableform" style="">
<div class="control-group form-group">
<div>
<div class="editable-input" style="position: relative;">
{{#unless resetForm}}
{{> inputTemplate}}
{{/unless}}
</div>
{{#if showbuttons}}
<div class="editable-buttons">
<button type="submit" class="btn btn-primary btn-sm editable-submit">
<i class="glyphicon glyphicon-ok"></i>
</button>
<button type="button" class="btn btn-default btn-sm editable-cancel">
<i class="glyphicon glyphicon-remove"></i>
</button>
</div>
{{/if}}
</div>
<div class="editable-error-block help-block" style="display: none;"></div>
</div>
</form>
</div>
{{else}}
<div class="editableform-loading">
Loading...
</div>
{{/unless}}
</div>
</div>
</template>
<template name="m_editable_main">
<span class="editable-container">
{{> m_editable_template
template=template
disabledTemplate=disabledTemplate
disabled=disabled
displayVal=displayVal
editableEmpty=editableEmpty
handle=handle
extraClasses=extraClasses
}}
<input type="hidden" class="editable-id" value="{{editableId}}" />
{{#unless appendToBody}}
{{>m_editable_popover}}
{{/unless}}
</span>
</template>
<body>
<div id="body-editables">
{{> m_editable_body_popovers}}
</div>
</body>
<template name="m_editable_body_popovers">
{{#each popovers}}
<div data-id="{{_id}}">
{{> m_editable_popover data}}
</div>
{{/each}}
</template>