Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Léo-Paul Géneau
gitlab-ce
Commits
03770698
Commit
03770698
authored
Jan 08, 2014
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use css truncation instead of rails
Signed-off-by:
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
parent
18fac587
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
38 additions
and
14 deletions
+38
-14
app/assets/stylesheets/generic/common.scss
app/assets/stylesheets/generic/common.scss
+9
-0
app/assets/stylesheets/sections/commits.scss
app/assets/stylesheets/sections/commits.scss
+4
-0
app/assets/stylesheets/sections/tree.scss
app/assets/stylesheets/sections/tree.scss
+4
-0
app/views/dashboard/_project.html.haml
app/views/dashboard/_project.html.haml
+7
-6
app/views/groups/_projects.html.haml
app/views/groups/_projects.html.haml
+3
-2
app/views/projects/commits/_commit.html.haml
app/views/projects/commits/_commit.html.haml
+2
-1
app/views/projects/issues/_issue.html.haml
app/views/projects/issues/_issue.html.haml
+2
-1
app/views/projects/tree/_blob_item.html.haml
app/views/projects/tree/_blob_item.html.haml
+2
-1
app/views/projects/tree/_tree_commit_column.html.haml
app/views/projects/tree/_tree_commit_column.html.haml
+3
-2
app/views/projects/tree/_tree_item.html.haml
app/views/projects/tree/_tree_item.html.haml
+2
-1
No files found.
app/assets/stylesheets/generic/common.scss
View file @
03770698
...
@@ -119,3 +119,12 @@ pre.well-pre {
...
@@ -119,3 +119,12 @@ pre.well-pre {
padding
:
0
;
padding
:
0
;
color
:
#666
;
color
:
#666
;
}
}
.str-truncated
{
display
:
inline-block
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
vertical-align
:
top
;
white-space
:
nowrap
;
max-width
:
82%
;
}
app/assets/stylesheets/sections/commits.scss
View file @
03770698
...
@@ -481,6 +481,10 @@ li.commit {
...
@@ -481,6 +481,10 @@ li.commit {
font-family
:
$monospace_font
;
font-family
:
$monospace_font
;
}
}
.str-truncated
{
max-width
:
70%
;
}
.commit-row-message
{
.commit-row-message
{
color
:
#333
;
color
:
#333
;
font-weight
:
500
;
font-weight
:
500
;
...
...
app/assets/stylesheets/sections/tree.scss
View file @
03770698
...
@@ -61,6 +61,10 @@
...
@@ -61,6 +61,10 @@
top
:
-1px
;
top
:
-1px
;
}
}
}
}
.tree_time_ago
{
min-width
:
135px
;
}
}
}
.tree_author
{
.tree_author
{
...
...
app/views/dashboard/_project.html.haml
View file @
03770698
=
link_to
project_path
(
project
),
class:
dom_class
(
project
)
do
=
link_to
project_path
(
project
),
class:
dom_class
(
project
)
do
.dash-project-access-icon
.dash-project-access-icon
=
visibility_level_icon
(
project
.
visibility_level
)
=
visibility_level_icon
(
project
.
visibility_level
)
%span
.namespace-name
%span
.str-truncated
-
if
project
.
namespace
%span
.namespace-name
=
project
.
namespace
.
human_name
-
if
project
.
namespace
\/
=
project
.
namespace
.
human_name
%span
.project-name.filter-title
\/
=
truncate
(
project
.
name
,
length:
25
)
%span
.project-name.filter-title
=
project
.
name
%span
.arrow
%span
.arrow
%i
.icon-angle-right
%i
.icon-angle-right
app/views/groups/_projects.html.haml
View file @
03770698
...
@@ -14,7 +14,8 @@
...
@@ -14,7 +14,8 @@
=
link_to
project_path
(
project
),
class:
dom_class
(
project
)
do
=
link_to
project_path
(
project
),
class:
dom_class
(
project
)
do
.dash-project-access-icon
.dash-project-access-icon
=
visibility_level_icon
(
project
.
visibility_level
)
=
visibility_level_icon
(
project
.
visibility_level
)
%span
.project-name
%span
.str-truncated
=
truncate
(
project
.
name
,
length:
25
)
%span
.project-name
=
truncate
(
project
.
name
,
length:
25
)
%span
.arrow
%span
.arrow
%i
.icon-angle-right
%i
.icon-angle-right
app/views/projects/commits/_commit.html.haml
View file @
03770698
...
@@ -2,7 +2,8 @@
...
@@ -2,7 +2,8 @@
.commit-row-title
.commit-row-title
=
link_to
commit
.
short_id
(
8
),
project_commit_path
(
project
,
commit
),
class:
"commit_short_id"
=
link_to
commit
.
short_id
(
8
),
project_commit_path
(
project
,
commit
),
class:
"commit_short_id"
=
link_to_gfm
truncate
(
commit
.
title
,
length:
70
),
project_commit_path
(
project
,
commit
.
id
),
class:
"commit-row-message"
%span
.str-truncated
=
link_to_gfm
commit
.
title
,
project_commit_path
(
project
,
commit
.
id
),
class:
"commit-row-message"
=
link_to
"Browse Code »"
,
project_tree_path
(
project
,
commit
),
class:
"pull-right"
=
link_to
"Browse Code »"
,
project_tree_path
(
project
,
commit
),
class:
"pull-right"
.notes_count
.notes_count
-
notes
=
project
.
notes
.
for_commit_id
(
commit
.
id
)
-
notes
=
project
.
notes
.
for_commit_id
(
commit
.
id
)
...
...
app/views/projects/issues/_issue.html.haml
View file @
03770698
...
@@ -5,7 +5,8 @@
...
@@ -5,7 +5,8 @@
.issue-title
.issue-title
%span
.light
=
"#
#{
issue
.
iid
}
"
%span
.light
=
"#
#{
issue
.
iid
}
"
=
link_to_gfm
truncate
(
issue
.
title
,
length:
100
),
project_issue_path
(
issue
.
project
,
issue
),
class:
"row_title"
%span
.str-truncated
=
link_to_gfm
issue
.
title
,
project_issue_path
(
issue
.
project
,
issue
),
class:
"row_title"
-
if
issue
.
closed?
-
if
issue
.
closed?
%small
.pull-right
%small
.pull-right
=
"CLOSED"
=
"CLOSED"
...
...
app/views/projects/tree/_blob_item.html.haml
View file @
03770698
%tr
{
class:
"tree-item #{tree_hex_class(blob_item)}"
}
%tr
{
class:
"tree-item #{tree_hex_class(blob_item)}"
}
%td
.tree-item-file-name
%td
.tree-item-file-name
=
tree_icon
(
type
)
=
tree_icon
(
type
)
%span
=
link_to
truncate
(
blob_item
.
name
,
length:
40
),
project_blob_path
(
@project
,
tree_join
(
@id
||
@commit
.
id
,
blob_item
.
name
))
%span
.str-truncated
=
link_to
blob_item
.
name
,
project_blob_path
(
@project
,
tree_join
(
@id
||
@commit
.
id
,
blob_item
.
name
))
%td
.tree_time_ago.cgray
%td
.tree_time_ago.cgray
%span
.log_loading.hide
%span
.log_loading.hide
Loading commit data...
Loading commit data...
...
...
app/views/projects/tree/_tree_commit_column.html.haml
View file @
03770698
%span
.tree_author
=
commit_author_link
(
commit
,
avatar:
true
,
size:
16
)
%span
.str-truncated
=
link_to_gfm
truncate
(
commit
.
title
,
length:
80
),
project_commit_path
(
@project
,
commit
.
id
),
class:
"tree-commit-link"
%span
.tree_author
=
commit_author_link
(
commit
,
avatar:
true
,
size:
16
)
=
link_to_gfm
commit
.
title
,
project_commit_path
(
@project
,
commit
.
id
),
class:
"tree-commit-link"
app/views/projects/tree/_tree_item.html.haml
View file @
03770698
%tr
{
class:
"tree-item #{tree_hex_class(tree_item)}"
}
%tr
{
class:
"tree-item #{tree_hex_class(tree_item)}"
}
%td
.tree-item-file-name
%td
.tree-item-file-name
=
tree_icon
(
type
)
=
tree_icon
(
type
)
%span
=
link_to
truncate
(
tree_item
.
name
,
length:
40
),
project_tree_path
(
@project
,
tree_join
(
@id
||
@commit
.
id
,
tree_item
.
name
))
%span
.str-truncated
=
link_to
tree_item
.
name
,
project_tree_path
(
@project
,
tree_join
(
@id
||
@commit
.
id
,
tree_item
.
name
))
%td
.tree_time_ago.cgray
%td
.tree_time_ago.cgray
%span
.log_loading.hide
%span
.log_loading.hide
Loading commit data...
Loading commit data...
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment