mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-12-31 04:32:06 +08:00
Fix long inventory names (#1999)
This commit is contained in:
parent
e2ad383c69
commit
0b85dcbead
2 changed files with 34 additions and 42 deletions
|
@ -68,37 +68,32 @@
|
|||
border-bottom: 1px solid $color-gainsboro;
|
||||
display: flex;
|
||||
margin-left: -20px;
|
||||
padding: 5px 20px;
|
||||
padding: 5px 15px;
|
||||
width: calc(100% + 40px);
|
||||
|
||||
.repository-share-icon {
|
||||
flex-shrink: 0;
|
||||
margin-top: -2px;
|
||||
|
||||
.fas-custom {
|
||||
margin-right: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
.repository-title {
|
||||
align-items: center;
|
||||
display: flex;
|
||||
flex-grow: 1;
|
||||
font-size: 18px;
|
||||
font-weight: 500;
|
||||
line-height: 50px;
|
||||
margin-right: 20px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
|
||||
span {
|
||||
white-space: nowrap;
|
||||
}
|
||||
.inline-editing-container {
|
||||
width: 100%;
|
||||
|
||||
.repository-share-icon {
|
||||
flex-shrink: 0;
|
||||
margin-right: 13px;
|
||||
margin-top: -2px;
|
||||
}
|
||||
|
||||
.repository-name {
|
||||
display: block;
|
||||
flex-grow: 1;
|
||||
margin-left: -10px;
|
||||
|
||||
.inline-editing-container {
|
||||
|
||||
input {
|
||||
line-height: 26px;
|
||||
}
|
||||
input {
|
||||
line-height: 26px;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -11,27 +11,24 @@
|
|||
|
||||
<div class="content-pane repository-show">
|
||||
<div id="repository-toolbar">
|
||||
<div class="repository-title">
|
||||
<span class="repository-share-icon">
|
||||
<% if @repository.shared_with?(current_team) %>
|
||||
<% if @repository.shared_with_write?(current_team) %>
|
||||
<%= draw_custom_icon('shared-edit') %>
|
||||
<% else %>
|
||||
<%= draw_custom_icon('shared-read') %>
|
||||
<% end %>
|
||||
<% elsif @repository.i_shared?(current_team) %>
|
||||
<%= draw_custom_icon('i-shared') %>
|
||||
<% end %>
|
||||
</span>
|
||||
<span class="repository-name">
|
||||
<% if @inline_editable_title_config.present? %>
|
||||
<%= render partial: "shared/inline_editing",
|
||||
locals: { initial_value: @repository.name } %>
|
||||
<span class="repository-share-icon">
|
||||
<% if @repository.shared_with?(current_team) %>
|
||||
<% if @repository.shared_with_write?(current_team) %>
|
||||
<%= draw_custom_icon('shared-edit') %>
|
||||
<% else %>
|
||||
<%= truncate(@repository.name,
|
||||
length: Constants::MAX_EDGE_LENGTH) %>
|
||||
<%= draw_custom_icon('shared-read') %>
|
||||
<% end %>
|
||||
</span>
|
||||
<% elsif @repository.i_shared?(current_team) %>
|
||||
<%= draw_custom_icon('i-shared') %>
|
||||
<% end %>
|
||||
</span>
|
||||
<div class="repository-title">
|
||||
<% if @inline_editable_title_config.present? %>
|
||||
<%= render partial: "shared/inline_editing",
|
||||
locals: { initial_value: @repository.name } %>
|
||||
<% else %>
|
||||
<%= @repository.name %>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<div id="datatables-buttons" class="datatables-buttons" style="display: inline;">
|
||||
|
|
Loading…
Reference in a new issue