mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-01 23:20:51 +00:00
[my libs, dir view] improvement: enlarge clickable area, and etc.
This commit is contained in:
@@ -232,7 +232,7 @@ a.table-sort-op {
|
|||||||
}
|
}
|
||||||
a.mobile-table-sort-op {
|
a.mobile-table-sort-op {
|
||||||
display:inline-block;
|
display:inline-block;
|
||||||
margin: 0 5px 0 10px;
|
margin: 0 7px 0 10px;
|
||||||
}
|
}
|
||||||
a.table-sort-op:hover,
|
a.table-sort-op:hover,
|
||||||
a.table-sort-op:focus {
|
a.table-sort-op:focus {
|
||||||
@@ -568,6 +568,12 @@ a.op-icon:focus {
|
|||||||
margin-top:4px;
|
margin-top:4px;
|
||||||
font-size:12px;
|
font-size:12px;
|
||||||
}
|
}
|
||||||
|
@media (max-width:767px) {
|
||||||
|
.more-op-icon {
|
||||||
|
padding:6px;
|
||||||
|
margin:0;
|
||||||
|
}
|
||||||
|
}
|
||||||
.big-more-btn {
|
.big-more-btn {
|
||||||
padding:.5em 0;
|
padding:.5em 0;
|
||||||
color:#777;
|
color:#777;
|
||||||
@@ -2196,6 +2202,12 @@ button.sf-dropdown-toggle:focus {
|
|||||||
.repo-file-list .dirent-name {
|
.repo-file-list .dirent-name {
|
||||||
display:inline-block;
|
display:inline-block;
|
||||||
}
|
}
|
||||||
|
@media (max-width:767px) {
|
||||||
|
.repo-file-list .dirent-name,
|
||||||
|
.repo-file-list .img-name-link {
|
||||||
|
display:block;
|
||||||
|
}
|
||||||
|
}
|
||||||
.repo-file-list .file-locked-icon {
|
.repo-file-list .file-locked-icon {
|
||||||
position:absolute;
|
position:absolute;
|
||||||
right:0;
|
right:0;
|
||||||
|
@@ -86,9 +86,6 @@
|
|||||||
<span class="repo-meta-info"><%= mtime_relative %></span>
|
<span class="repo-meta-info"><%= mtime_relative %></span>
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
<% } else { %>
|
|
||||||
<td>{% trans "Broken (please contact your administrator to fix this library)" %}</td>
|
|
||||||
<% } %>
|
|
||||||
<td class="repo-op-td">
|
<td class="repo-op-td">
|
||||||
<div class="op-container">
|
<div class="op-container">
|
||||||
<div class="sf-dropdown sf-dropdown-inline">
|
<div class="sf-dropdown sf-dropdown-inline">
|
||||||
@@ -112,6 +109,10 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
<% } else { %>
|
||||||
|
<td>{% trans "Broken (please contact your administrator to fix this library)" %}</td>
|
||||||
|
<td></td>
|
||||||
|
<% } %>
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<script type="text/template" id="group-repo-tmpl">
|
<script type="text/template" id="group-repo-tmpl">
|
||||||
@@ -550,8 +551,8 @@
|
|||||||
<a class="normal img-name-link" href="<%= url %>" target="_blank"><%- dirent.obj_name %></a>
|
<a class="normal img-name-link" href="<%= url %>" target="_blank"><%- dirent.obj_name %></a>
|
||||||
<% } else { %>
|
<% } else { %>
|
||||||
<a class="normal" href="<%= url %>" target="_blank"><%- dirent.obj_name %></a>
|
<a class="normal" href="<%= url %>" target="_blank"><%- dirent.obj_name %></a>
|
||||||
<% } %>
|
|
||||||
<br />
|
<br />
|
||||||
|
<% } %>
|
||||||
<span class="dirent-meta-info"><%= dirent.file_size %></span>
|
<span class="dirent-meta-info"><%= dirent.file_size %></span>
|
||||||
<span class="dirent-meta-info">
|
<span class="dirent-meta-info">
|
||||||
<% if (dirent.last_modified) { %>
|
<% if (dirent.last_modified) { %>
|
||||||
|
@@ -81,6 +81,7 @@ define([
|
|||||||
events: {
|
events: {
|
||||||
'click .select': 'select',
|
'click .select': 'select',
|
||||||
'click .file-star': 'starFile',
|
'click .file-star': 'starFile',
|
||||||
|
'click .dirent-name': 'visitDirent',
|
||||||
'click .img-name-link': 'viewImageWithPopup',
|
'click .img-name-link': 'viewImageWithPopup',
|
||||||
|
|
||||||
// mv by 'drag & drop'
|
// mv by 'drag & drop'
|
||||||
@@ -337,6 +338,13 @@ define([
|
|||||||
return false;
|
return false;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
visitDirent: function() {
|
||||||
|
if ($(window).width() < 768 &&
|
||||||
|
!this.model.get('is_img')) { // dir or non image file
|
||||||
|
location.href = this.$('.dirent-name a').attr('href');
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
viewImageWithPopup: function() {
|
viewImageWithPopup: function() {
|
||||||
var index = $('.img-name-link', this.dirView.$dirent_list).index(this.$('.img-name-link'));
|
var index = $('.img-name-link', this.dirView.$dirent_list).index(this.$('.img-name-link'));
|
||||||
$.magnificPopup.open(this.dirView.magnificPopupOptions, index);
|
$.magnificPopup.open(this.dirView.magnificPopupOptions, index);
|
||||||
|
@@ -24,6 +24,7 @@ define([
|
|||||||
transferTemplate: _.template($('#repo-transfer-form-tmpl').html()),
|
transferTemplate: _.template($('#repo-transfer-form-tmpl').html()),
|
||||||
|
|
||||||
events: {
|
events: {
|
||||||
|
'click td:lt(2)': 'visitRepo',
|
||||||
'click .repo-delete-btn': 'del',
|
'click .repo-delete-btn': 'del',
|
||||||
'click .repo-share-btn': 'share',
|
'click .repo-share-btn': 'share',
|
||||||
'click .js-repo-rename': 'rename',
|
'click .js-repo-rename': 'rename',
|
||||||
@@ -64,6 +65,12 @@ define([
|
|||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
visitRepo: function() {
|
||||||
|
if ($(window).width() < 768) {
|
||||||
|
location.href = this.$('.repo-name-span a').attr('href');
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
del: function() {
|
del: function() {
|
||||||
var _this = this;
|
var _this = this;
|
||||||
var repo_name = this.model.get('name');
|
var repo_name = this.model.get('name');
|
||||||
|
Reference in New Issue
Block a user