mirror of
https://github.com/haiwen/seahub.git
synced 2025-07-01 01:12:41 +00:00
accessibility improvement; bugfix & clean up
This commit is contained in:
parent
ef980da1ec
commit
f466979760
@ -255,7 +255,8 @@ textarea:focus {
|
||||
border-color: #66afe9;
|
||||
outline: none;
|
||||
}
|
||||
input[type="checkbox"]:focus {
|
||||
input[type="checkbox"]:focus,
|
||||
input[type="radio"]:focus {
|
||||
outline:#66afe9 auto 1px;
|
||||
}
|
||||
input::-webkit-outer-spin-button,
|
||||
@ -348,6 +349,7 @@ p { margin:0.5em 0; }
|
||||
.fright { float:right }
|
||||
.clear { clear:both; }
|
||||
.show { display:block }
|
||||
.inline-block { display: inline-block; }
|
||||
.hide { display:none }
|
||||
.error { color:red; }
|
||||
.errorlist { color: red; }
|
||||
@ -363,7 +365,6 @@ p { margin:0.5em 0; }
|
||||
.label { color:#333; font-size:12px; font-style:normal; }
|
||||
.italic { font-style:italic; }
|
||||
.alc { text-align: center;}
|
||||
.inline-block { display: inline-block; }
|
||||
.cspt { cursor:pointer; }
|
||||
.pos-rel { position:relative; }
|
||||
.top-tip {
|
||||
@ -440,12 +441,6 @@ p { margin:0.5em 0; }
|
||||
display:block;
|
||||
margin:1em auto;
|
||||
}
|
||||
.icon-plus, .icon-minus, .icon-pencil {
|
||||
font-size:16px;
|
||||
line-height:1;
|
||||
color:#444;
|
||||
margin-left:3px;
|
||||
}
|
||||
.op,
|
||||
.more {
|
||||
font-weight:normal;
|
||||
@ -1062,9 +1057,11 @@ textarea:-moz-placeholder {/* for FF */
|
||||
#simplemodal-container label {
|
||||
margin:8px 0 4px;
|
||||
}
|
||||
#simplemodal-container .radio-item,
|
||||
#simplemodal-container .checkbox-option {
|
||||
font-weight:normal;
|
||||
}
|
||||
#simplemodal-container .radio-item,
|
||||
#simplemodal-container .checkbox-label {
|
||||
margin:4px 0;
|
||||
}
|
||||
@ -1307,12 +1304,12 @@ button.dropdown-toggle:focus {
|
||||
width:350px;
|
||||
padding:3px 5px;
|
||||
}
|
||||
.msg-form .submit {
|
||||
.msg-submit {
|
||||
color:#fff;
|
||||
background:#4abb49;
|
||||
border:1px solid #5cb25b;
|
||||
}
|
||||
.msg-form .submit:hover {
|
||||
.msg-submit:hover {
|
||||
background:#55ab22;
|
||||
}
|
||||
.no-discussion-tip {
|
||||
@ -1387,7 +1384,7 @@ button.dropdown-toggle:focus {
|
||||
#organization-repos .hd {
|
||||
position:relative;
|
||||
}
|
||||
#group-top .op-icon {
|
||||
.group-top-op-icon {
|
||||
display:inline-block;
|
||||
font-size:22px;
|
||||
margin:4px 15px 0 0;
|
||||
@ -1433,7 +1430,7 @@ button.dropdown-toggle:focus {
|
||||
text-decoration:none;
|
||||
border-bottom-color: #eb8205;
|
||||
}
|
||||
#right-panel .hd button,
|
||||
.btn-white,
|
||||
.tabnav button,
|
||||
.repo-file-list-topbar .op-btn,
|
||||
.wiki-top .op-btn {
|
||||
@ -1857,13 +1854,9 @@ button.dropdown-toggle:focus {
|
||||
.repo-op .op-btn {
|
||||
vertical-align:middle;
|
||||
}
|
||||
#featured-filetype {
|
||||
margin:5px 0;
|
||||
}
|
||||
#featured-filetype button {
|
||||
.set-file-type {
|
||||
padding: 2px;
|
||||
line-height: 1.2;
|
||||
border: 1px solid #bbb;
|
||||
margin: 2px 0 5px;
|
||||
}
|
||||
.file-audit-list-topbar .path,
|
||||
@ -2813,24 +2806,11 @@ button.dropdown-toggle:focus {
|
||||
#search-user-form .submit {
|
||||
margin-left:3.5em;
|
||||
}
|
||||
#myhome-enable-mods,
|
||||
#enable-mods {
|
||||
.enable-mods-icon {
|
||||
margin:3px 0 0;
|
||||
color:#ccc;
|
||||
font-size:18px;
|
||||
}
|
||||
#edit-index {
|
||||
color:#d7d7d7;
|
||||
margin-top:3px;
|
||||
}
|
||||
#edit-index:hover {
|
||||
color:#666;
|
||||
cursor:pointer;
|
||||
}
|
||||
#add-msg .icon-pencil {
|
||||
font-size:1em;
|
||||
margin:0 3px 0 0;
|
||||
}
|
||||
.help-con {
|
||||
padding:0 0 0 30px;
|
||||
}
|
||||
@ -2848,23 +2828,28 @@ button.dropdown-toggle:focus {
|
||||
.wiki-index h3 {
|
||||
color:#333;
|
||||
}
|
||||
.wiki-index-edit-icon {
|
||||
font-size:16px;
|
||||
color:#d7d7d7;
|
||||
margin:3px 0 0;
|
||||
}
|
||||
#wiki-index-con {
|
||||
padding-left:12px;
|
||||
}
|
||||
.grp-wiki-index #wiki-index-con {
|
||||
padding:0;
|
||||
}
|
||||
.wiki-index ul {
|
||||
#wiki-index-con ul {
|
||||
list-style-type: square;
|
||||
padding-left: 1.5em;
|
||||
margin-bottom:5px;
|
||||
color:#8c8c8c;
|
||||
}
|
||||
.wiki-index a {
|
||||
#wiki-index-con a {
|
||||
font-weight:normal;
|
||||
color:#8c8c8c;
|
||||
}
|
||||
.wiki-index a:hover {
|
||||
#wiki-index-con a:hover {
|
||||
color:#f93;
|
||||
text-decoration:underline;
|
||||
}
|
||||
|
@ -4,18 +4,10 @@
|
||||
|
||||
{% block sub_title %}{{group.group_name}} - {% endblock %}
|
||||
|
||||
{% block cur_group %}cur{% endblock %}
|
||||
|
||||
{% block left_panel %}
|
||||
<div class="side-tabnav">
|
||||
<div class="hd w100 ovhd">
|
||||
<h3 class="fleft">
|
||||
{% grp_avatar group.props.id 32 %} <a title="{{ group.group_name }}" class="grp-name ellipsis vam" href="{% url 'group_info' group.id %}">{{ group.group_name }}</a>
|
||||
</h3>
|
||||
</div>
|
||||
<h3 class="hd">
|
||||
{% grp_avatar group.props.id 32 %} <a title="{{ group.group_name }}" class="grp-name ellipsis vam" href="{% url 'group_info' group.id %}">{{ group.group_name }}</a>
|
||||
</h3>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
{% block main_panel %}
|
||||
|
||||
{% endblock %}
|
||||
|
@ -19,7 +19,7 @@
|
||||
<div class="hd ovhd">
|
||||
<h3 class="fleft">{% trans "Wiki Index" %}</h3>
|
||||
{% if repo_perm == 'rw' %}
|
||||
<span id="edit-index" class="icon-pencil fright" title="{% trans "Edit" %}"></span>
|
||||
<a id="edit-index" class="wiki-index-edit-icon op-icon icon-pencil fright" title="{% trans "Edit" %}" aria -label="{% trans "Edit" %}" href="#"></a>
|
||||
{% endif %}
|
||||
</div>
|
||||
<div id="wiki-index-con"></div>
|
||||
@ -227,11 +227,9 @@ $('#wiki-use-lib-form').submit(function() {
|
||||
{% if wiki_index_exists %}
|
||||
$('#wiki-index-con').html(marked('{{ index_content|escapejs }}'));
|
||||
{% if repo_perm == 'rw' %}
|
||||
$('#edit-index').click(function() {
|
||||
{% with page_name='index' %}
|
||||
location.href = "{% url 'group_wiki_page_edit' group.id page_name %}";
|
||||
$('#edit-index').attr('href', "{% url 'group_wiki_page_edit' group.id page_name %}");
|
||||
{% endwith %}
|
||||
});
|
||||
{% endif %}
|
||||
{% else %}
|
||||
{% if repo_perm == 'rw' %}
|
||||
|
@ -6,7 +6,7 @@
|
||||
{% block right_panel %}
|
||||
<div class="hd ovhd">
|
||||
<h3 class="fleft">{% trans "All Notifications" %}</h3>
|
||||
<button id="add-n" class="fright">{% trans "Add new notification" %}</button>
|
||||
<button id="add-n" class="fright btn-white">{% trans "Add new notification" %}</button>
|
||||
</div>
|
||||
<form action="{% url 'notification_add' %}" method="post" class="hide" id="add-n-form">{% csrf_token %}
|
||||
<h3>{% trans "Add new notification" %}</h3>
|
||||
|
@ -37,7 +37,7 @@
|
||||
<div class="hd w100 ovhd">
|
||||
<h3 class="fleft">{% trans "Tools" %}</h3>
|
||||
{% if user.permissions.can_add_repo %}
|
||||
<span id="enable-mods" class="sf2-icon-cog2 op-icon fright" title="{% trans "Enable Modules" %}"></span>
|
||||
<a href="#" id="enable-mods" class="sf2-icon-cog2 op-icon enable-mods-icon fright" title="{% trans "Enable Modules" %}" aria-label="{% trans "Enable Modules" %}"></a>
|
||||
{% endif %}
|
||||
</div>
|
||||
<ul class="side-tabnav-tabs">
|
||||
|
@ -115,7 +115,7 @@
|
||||
</script>
|
||||
|
||||
<script type="text/template" id="admin-devices-tmpl">
|
||||
<div class="hd">
|
||||
<div class="hd ovhd">
|
||||
<ul class="tab-tabs-nav fleft">
|
||||
<li class="tab <% if (cur_tab == 'desktop') { %> ui-state-active <% } %>">
|
||||
<a href="#desktop-devices/" class="a">{% trans "Desktop" %}</a>
|
||||
@ -168,7 +168,7 @@
|
||||
</script>
|
||||
|
||||
<script type="text/template" id="admin-device-errors-tmpl">
|
||||
<div class="hd">
|
||||
<div class="hd ovhd">
|
||||
<ul class="tab-tabs-nav fleft">
|
||||
<li class="tab <% if (cur_tab == 'desktop') { %> ui-state-active <% } %>">
|
||||
<a href="#desktop-devices/" class="a">{% trans "Desktop" %}</a>
|
||||
|
@ -70,7 +70,7 @@
|
||||
<td><a href="#group/<%= group_id %>/lib/<%= id %>"><%- name %></a></td>
|
||||
<td class="alc">
|
||||
<% if (is_staff || share_from_me) { %>
|
||||
<a href="#" class="sf2-icon-delete sf2-x cancel-share op-icon vh" title="{% trans "Unshare" %}"></a>
|
||||
<a href="#" class="sf2-icon-delete sf2-x cancel-share op-icon vh" title="{% trans "Unshare" %}" aria-label="{% trans "Unshare" %}"></a>
|
||||
<% } %>
|
||||
</td>
|
||||
<td><%= size_formatted %></td>
|
||||
@ -101,6 +101,15 @@
|
||||
<button id="del-dirents" title="{% trans 'Delete' %}" class="op-btn sf2-icon-delete op-icon"></button>
|
||||
<button id="download-dirents" title="{% trans 'Download' %}" class="op-btn sf2-icon-download op-icon"></button>
|
||||
</div>
|
||||
<% } %>
|
||||
<% if (!encrypted && user_perm == 'r') { %>
|
||||
<div id="multi-dirents-op" class="hide">
|
||||
<button id="cp-dirents" title="{% trans 'Copy' %}" class="op-btn sf2-icon-copy op-icon"></button>
|
||||
</div>
|
||||
<% } %>
|
||||
|
||||
<div id="cur-dir-ops" class="inline-block">
|
||||
<% if (user_perm == 'rw') { %>
|
||||
<div id="basic-upload" class="inline-block">
|
||||
<button class="op-btn basic-upload-btn" >{% trans "Upload" %}</button>
|
||||
<input id="basic-upload-input" class="hide" type="file" name="file" multiple />
|
||||
@ -124,15 +133,10 @@
|
||||
<button id="add-new-file" class="op-btn">{% trans "New File" %}</button>
|
||||
<% } %>
|
||||
|
||||
<% if (!encrypted && user_perm == 'r') { %>
|
||||
<div id="multi-dirents-op" class="hide">
|
||||
<button id="cp-dirents" title="{% trans 'Copy' %}" class="op-btn sf2-icon-copy op-icon"></button>
|
||||
</div>
|
||||
<% } %>
|
||||
|
||||
<% if (!encrypted && can_generate_shared_link) { %>
|
||||
<button class="op-btn" id="share-cur-dir">{% trans "Share" %}</button>
|
||||
<% } %>
|
||||
</div><!-- div#cur-dir-ops ends here -->
|
||||
|
||||
<div class="switch-mode vam">
|
||||
<button class="list-view-icon-btn sf2-icon-list-view <% if (mode == 'list') { %>active<% } %>" title="{% trans "List" %}" id="js-switch-list-view" aria-label="{% trans "list view" %}"></button><button class="grid-view-icon-btn sf2-icon-grid-view <% if (mode == 'grid') { %>active<% } %>" title="{% trans "Grid" %}" id="js-switch-grid-view" aria-label="{% trans "grid view" %}"></button>
|
||||
@ -409,20 +413,6 @@
|
||||
</ul>
|
||||
</script>
|
||||
|
||||
<script type="text/template" id="group-change-item-tmpl">
|
||||
<td>
|
||||
<span class="icon-plus"></span>
|
||||
</td>
|
||||
<td><a href="#"><%= repo.name %></a></td>
|
||||
<td>
|
||||
<%= desc_human %>
|
||||
<a class="lsch" >{% trans 'Details' %}</a>
|
||||
</td>
|
||||
<td><%= ctime_human %></td>
|
||||
<td>
|
||||
<%- creator_nickname %>
|
||||
</td>
|
||||
</script>
|
||||
<script type="text/template" id="share-popup-tmpl">
|
||||
<h3 class="hd"><%= title %></h3>
|
||||
<div id="share-tabs" class="left-right-tabs ovhd">
|
||||
@ -665,7 +655,7 @@
|
||||
<div class="hd w100 ovhd">
|
||||
<h3 class="fleft">{% trans "Tools" %}</h3>
|
||||
{% if user.permissions.can_add_repo %}
|
||||
<a href="#" id="enable-mods" class="sf2-icon-cog2 op-icon fright" title="{% trans "Enable Modules" %}" aria-label="{% trans "Enable Modules" %}"></a>
|
||||
<a href="#" id="enable-mods" class="sf2-icon-cog2 op-icon enable-mods-icon fright" title="{% trans "Enable Modules" %}" aria-label="{% trans "Enable Modules" %}"></a>
|
||||
{% endif %}
|
||||
</div>
|
||||
<ul class="side-tabnav-tabs">
|
||||
@ -731,16 +721,16 @@
|
||||
<p class="path"><a href="{% url 'group_list' %}" class="normal">{% trans "Groups" %}</a> / <%- name %></p>
|
||||
<div class="hd ovhd">
|
||||
{% if user.permissions.can_add_repo %}
|
||||
<button class="repo-create fleft"><span class="icon-plus-square add vam"></span><span class="vam">{% trans "New Library" %}</span></button>
|
||||
<button class="repo-create btn-white fleft"><span class="icon-plus-square add vam"></span><span class="vam">{% trans "New Library" %}</span></button>
|
||||
{% endif %}
|
||||
|
||||
<div class="fright">
|
||||
<% if (wiki_enabled) { %>
|
||||
<a href="{{SITE_ROOT}}group/<%= id %>/wiki/" class="sf2-icon-wiki2 op-icon" title="{% trans "Wiki" %}" id="group-wiki-icon"></a>
|
||||
<a href="{{SITE_ROOT}}group/<%= id %>/wiki/" class="sf2-icon-wiki2 op-icon group-top-op-icon" title="{% trans "Wiki" %}" id="group-wiki-icon"></a>
|
||||
<% } %>
|
||||
<a href="#" class="sf2-icon-cog1 op-icon" title="{% trans "Settings" %}" id="group-settings-icon" aria-label="{% trans "Settings" %}"></a>
|
||||
<a href="#" class="sf2-icon-user2 op-icon" title="{% trans "Members" %}" id="group-members-icon" aria-label="{% trans "Members" %}"></a>
|
||||
<a href="#" class="sf2-icon-msgs2 op-icon" title="{% trans "Discussion" %}" id="group-discussions-icon" aria-label="{% trans "Discussion" %}"></a>
|
||||
<a href="#" class="sf2-icon-cog1 op-icon group-top-op-icon" title="{% trans "Settings" %}" id="group-settings-icon" aria-label="{% trans "Settings" %}"></a>
|
||||
<a href="#" class="sf2-icon-user2 op-icon group-top-op-icon" title="{% trans "Members" %}" id="group-members-icon" aria-label="{% trans "Members" %}"></a>
|
||||
<a href="#" class="sf2-icon-msgs2 op-icon group-top-op-icon" title="{% trans "Discussion" %}" id="group-discussions-icon" aria-label="{% trans "Discussion" %}"></a>
|
||||
</div>
|
||||
</div>
|
||||
</script>
|
||||
@ -846,7 +836,7 @@
|
||||
<td><%- repo_name %></td>
|
||||
<td><%= mtime_relative %></td>
|
||||
<td>
|
||||
<a href="#" class="sf2-icon-delete unstar op-icon vh" title="{% trans "Unstar" %}"></a>
|
||||
<a href="#" class="sf2-icon-delete unstar op-icon vh" title="{% trans "Unstar" %}" aria-label="{% trans "Unstar" %}"></a>
|
||||
</td>
|
||||
</script>
|
||||
|
||||
@ -989,14 +979,14 @@
|
||||
<img src="<%= avatar_url %>" alt="" width="32" class="avatar-circle fleft" />
|
||||
<div class="msg-body">
|
||||
<div class="ovhd">
|
||||
<div class="msg-ops fright vh">
|
||||
<span class="msg-op sf2-icon-reply op-icon js-reply-msg" title="{% trans "Reply" %}"></span>
|
||||
<% if (can_delete_msg) { %>
|
||||
<span class="msg-op sf2-icon-delete op-icon js-del-msg" title="{% trans "Delete" %}"></span>
|
||||
<% } %>
|
||||
</div>
|
||||
<a class="msg-username ellipsis" title="<%- user_name %>" href="<%= user_profile_url %>"><%- user_name %></a>
|
||||
<span class="msg-time" title="<%- time %>"><%- time_from_now %></span>
|
||||
<div class="msg-ops fright vh">
|
||||
<a class="msg-op sf2-icon-reply op-icon js-reply-msg" title="{% trans "Reply" %}" aria-label="{% trans "Reply" %}" href="#"></a>
|
||||
<% if (can_delete_msg) { %>
|
||||
<a class="msg-op sf2-icon-delete op-icon js-del-msg" title="{% trans "Delete" %}" aria-label="{% trans "Delete" %}" href="#"></a>
|
||||
<% } %>
|
||||
</div>
|
||||
</div>
|
||||
<div class="msg-content"><%= content_marked %></div>
|
||||
</div>
|
||||
@ -1154,16 +1144,25 @@
|
||||
<p class="history-settings-notice outstanding-tip hide">{% trans "Setting library history is disabled by Admin" %}</p>
|
||||
|
||||
<form action="" method="post">
|
||||
<label class="radio-item">
|
||||
<input type="radio" name="history" value="full_history" class="vam" />
|
||||
<span class="vam">{% trans "Keep full history" %}</span><br />
|
||||
<span class="vam">{% trans "Keep full history" %}</span>
|
||||
</label>
|
||||
<br />
|
||||
|
||||
<label class="radio-item">
|
||||
<input type="radio" name="history" value="no_history" class="vam" />
|
||||
<span class="vam">{% trans "Don't keep history" %}</span><br />
|
||||
<span class="vam">{% trans "Don't keep history" %}</span>
|
||||
</label>
|
||||
<br />
|
||||
|
||||
<label class="radio-item">
|
||||
<input type="radio" name="history" value="partial_history" class="vam" />
|
||||
<span calss="vam">{% trans "Only keep a period of history:" %}
|
||||
<input type="text" name="days" size="4" disabled="disabled" class="input-disabled" value="<%= default_history_limit %>" /> {% trans "days" %}
|
||||
</span><br />
|
||||
</span>
|
||||
</label>
|
||||
<br />
|
||||
|
||||
<input type="submit" value="{% trans "Submit" %}" class="submit" />
|
||||
</form>
|
||||
|
@ -11,7 +11,7 @@
|
||||
<script type="text/template" id="my-own-repos-tmpl">
|
||||
<div class="hd ovhd">
|
||||
<h3 class="fleft">{% trans "Mine" %}</h3>
|
||||
<button class="repo-create fright"><span aria-hidden="true" class="icon-plus-square add vam"></span><span class="vam">{% trans "New Library" %}</span></button>
|
||||
<button class="repo-create btn-white fright"><span aria-hidden="true" class="icon-plus-square add vam"></span><span class="vam">{% trans "New Library" %}</span></button>
|
||||
</div>
|
||||
<table class="my-own-repos-table hide">
|
||||
<thead></thead>
|
||||
@ -39,11 +39,11 @@
|
||||
</script>
|
||||
|
||||
<script type="text/template" id="organization-repos-tmpl">
|
||||
<div class="hd">
|
||||
<div class="hd">{# no 'ovhd' as there is a .dropdown-menu in it #}
|
||||
<h3 class="fleft">{% trans "Organization" %}</h3>
|
||||
{% if can_add_pub_repo %}
|
||||
<div class="fright dropdown js-add-pub-lib-dropdown">
|
||||
<button class="dropdown-toggle"><span aria-hidden="true" class="icon-plus-square add vam"></span><span class="vam">{% trans "Add Library"%}</span></button>
|
||||
<button class="btn-white dropdown-toggle"><span aria-hidden="true" class="icon-plus-square add vam"></span><span class="vam">{% trans "Add Library"%}</span></button>
|
||||
<ul class="dropdown-menu hide">
|
||||
<li><a class="op share-existing" href="#">{% trans "Share existing libraries" %}</a></li>
|
||||
<li><a class="op create-new" href="#">{% trans "Create a new library" %}</a></li>
|
||||
@ -68,7 +68,7 @@
|
||||
<div class="hd ovhd">
|
||||
<h3 class="fleft">{% trans "My Groups" %}</h3>
|
||||
{% if user.permissions.can_add_group %}
|
||||
<button id="add-group" class="fright"><span aria-hidden="true" class="icon-plus-square add vam"></span><span class="vam">{% trans "New Group" %}</span></button>
|
||||
<button id="add-group" class="btn-white fright"><span aria-hidden="true" class="icon-plus-square add vam"></span><span class="vam">{% trans "New Group" %}</span></button>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
@ -154,7 +154,7 @@
|
||||
<img src="{% avatar_url request.user 64 %}" alt="" width="32" class="avatar-circle fleft" />
|
||||
<div class="msg-body">
|
||||
<textarea name="message" placeholder="{% trans "Add a discussion..." %}" class="msg-input"></textarea>
|
||||
<button type="submit" class="submit">{% trans "Submit" %}</button>
|
||||
<button type="submit" class="submit msg-submit">{% trans "Submit" %}</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
@ -18,7 +18,7 @@
|
||||
{% else %}
|
||||
<div class="hd ovhd">
|
||||
<h3 class="fleft">{% trans "Wiki Index" %}</h3>
|
||||
<span id="edit-index" class="icon-pencil fright" title="{% trans "Edit" %}"></span>
|
||||
<a id="edit-index" class="wiki-index-edit-icon op-icon icon-pencil fright" title="{% trans "Edit" %}" aria-label="{% trans "Edit" %}" href="#"></a>
|
||||
</div>
|
||||
<div id="wiki-index-con"></div>
|
||||
{% endif %}
|
||||
@ -220,9 +220,7 @@ $('#wiki-use-lib-form').submit(function() {
|
||||
{% if wiki_index_exists %}
|
||||
$('#wiki-index-con').html(marked('{{ index_content|escapejs }}'));
|
||||
{% with page_name='index' %}
|
||||
$('#edit-index').click(function() {
|
||||
location.href = "{% url 'personal_wiki_page_edit' page_name %}";
|
||||
});
|
||||
$('#edit-index').attr('href', "{% url 'personal_wiki_page_edit' page_name %}");
|
||||
{% endwith %}
|
||||
{% else %}
|
||||
$('#create-index').click(function() {
|
||||
|
@ -65,6 +65,7 @@ define([
|
||||
_this.$days_input.prop('disabled', false).removeClass('input-disabled');
|
||||
_this.$days_input.attr('value', data.keep_days);
|
||||
}
|
||||
_this.$radios.filter(':checked').focus();
|
||||
|
||||
if (!app.pageOptions.enable_repo_history_setting) {
|
||||
_this.$('.history-settings-notice').removeClass('hide');
|
||||
|
@ -546,6 +546,7 @@ define([
|
||||
focus: false,
|
||||
containerCss: {'padding':'20px 25px'}
|
||||
});
|
||||
file_name.focus();
|
||||
$('#simplemodal-container').css({'height':'auto'});
|
||||
|
||||
$('.set-file-type', form).click(function() {
|
||||
@ -781,7 +782,7 @@ define([
|
||||
var $all_dirent_checkbox = this.$('[type=checkbox]');
|
||||
var $dirents_op = this.$('#multi-dirents-op');
|
||||
|
||||
var $curDirOps = this.$('#upload-file, #add-new-dir, #add-new-file, #share-cur-dir');
|
||||
var $curDirOps = this.$('#cur-dir-ops');
|
||||
|
||||
if ($el.prop('checked')) {
|
||||
$all_dirent_checkbox.prop('checked', true);
|
||||
|
@ -103,7 +103,7 @@ define([
|
||||
}
|
||||
});
|
||||
|
||||
var $curDirOps = dirView.$('#upload-file, #add-new-dir, #add-new-file, #share-cur-dir');
|
||||
var $curDirOps = dirView.$('#cur-dir-ops');
|
||||
|
||||
if (checked_num > 0) {
|
||||
$dirents_op.css({'display':'inline-block'});
|
||||
@ -211,6 +211,7 @@ define([
|
||||
}).append(form);
|
||||
$op.hide();
|
||||
$name.hide();
|
||||
$('[name="newname"]', form).focus();
|
||||
|
||||
this._hideMenu();
|
||||
app.ui.freezeItemHightlight = true;
|
||||
|
@ -17,6 +17,7 @@ define([
|
||||
events: {
|
||||
'mouseenter': 'highlight',
|
||||
'mouseleave': 'rmHighlight',
|
||||
'focus *': 'focusItem',
|
||||
'click .js-del-msg': 'delMessage',
|
||||
'click .js-reply-msg': 'reply'
|
||||
},
|
||||
@ -67,8 +68,17 @@ define([
|
||||
this.$('.msg-ops').addClass('vh');
|
||||
},
|
||||
|
||||
focusItem: function() {
|
||||
$('.msg.hl', this.$el.parent())
|
||||
.removeClass('hl')
|
||||
.find('.msg-ops').addClass('vh');
|
||||
|
||||
this.highlight();
|
||||
},
|
||||
|
||||
reply: function() {
|
||||
this.parentView.replyTo(this.model.get("user_name"));
|
||||
return false;
|
||||
},
|
||||
|
||||
delMessage: function() {
|
||||
@ -86,6 +96,7 @@ define([
|
||||
Common.feedback(err, 'error');
|
||||
}
|
||||
});
|
||||
return false;
|
||||
}
|
||||
|
||||
});
|
||||
|
@ -115,7 +115,7 @@ define([
|
||||
}
|
||||
});
|
||||
|
||||
$("#group").append(this.$el);
|
||||
$("#group-discussions-icon").after(this.$el);
|
||||
this.$(".msg-input").focus();
|
||||
app.router.navigate('group/' + this.groupView.group.id + '/discussions/');
|
||||
},
|
||||
|
@ -77,7 +77,7 @@ define([
|
||||
_this.$error.html(err_msg).show();
|
||||
}
|
||||
});
|
||||
$("#group").append(this.$el);
|
||||
$("#group-members-icon").after(this.$el);
|
||||
}
|
||||
|
||||
});
|
||||
|
@ -53,7 +53,7 @@ define([
|
||||
'wiki_enabled': this.groupView.group.wiki_enabled
|
||||
}));
|
||||
|
||||
$("#group").append(this.$el);
|
||||
$("#group-settings-icon").after(this.$el);
|
||||
},
|
||||
|
||||
highlightItem: function(e) {
|
||||
@ -99,7 +99,7 @@ define([
|
||||
var _this = this;
|
||||
|
||||
var $form = $(this.renameTemplate());
|
||||
$form.modal({focus:false});
|
||||
$form.modal();
|
||||
$('#simplemodal-container').css({'width':'auto', 'height':'auto'});
|
||||
|
||||
$form.submit(function() {
|
||||
|
@ -13,7 +13,7 @@ define([
|
||||
'use strict';
|
||||
|
||||
var OrganizationView = Backbone.View.extend({
|
||||
id: 'organization-repos-tmpl',
|
||||
id: 'organization',
|
||||
|
||||
template: _.template($('#organization-repos-tmpl').html()),
|
||||
reposHdTemplate: _.template($('#shared-repos-hd-tmpl').html()),
|
||||
|
@ -63,9 +63,9 @@ define([
|
||||
.replace('{lib_name}', '<span class="op-target">' + Common.HTMLescape(this.model.get('name')) + '</span>');
|
||||
var confirm_popup = $(this.repoDelConfirmTemplate({
|
||||
content: confirm_msg
|
||||
}))
|
||||
.appendTo(op_container)
|
||||
.css({
|
||||
}));
|
||||
del_icon.after(confirm_popup);
|
||||
confirm_popup.css({
|
||||
'left': del_icon.position().left,
|
||||
'top': del_icon.position().top + del_icon.height() + 2,
|
||||
'width': 180
|
||||
@ -144,6 +144,7 @@ define([
|
||||
}).append(form);
|
||||
$op_td.hide();
|
||||
$name_span.hide();
|
||||
$('[name="newname"]', form).focus();
|
||||
|
||||
this.togglePopup();
|
||||
app.ui.freezeItemHightlight = true;
|
||||
|
Loading…
Reference in New Issue
Block a user