File tree Expand file tree Collapse file tree 3 files changed +24
-34
lines changed Expand file tree Collapse file tree 3 files changed +24
-34
lines changed Original file line number Diff line number Diff line change 33 <h4 class="ui top attached header">
44 {{.locale.Tr "admin.notices.system_notice_list"}} ({{.locale.Tr "admin.total" .Total}})
55 </h4>
6- <table id="notice-table" class="ui attached basic select selectable table unstackable">
6+ <table class="ui attached basic select selectable table unstackable g-table-auto-ellipsis ">
77 <thead>
88 <tr>
99 <th></th>
1010 <th>ID</th>
1111 <th>{{.locale.Tr "admin.notices.type"}}</th>
1212 <th>{{.locale.Tr "admin.notices.desc"}}</th>
13- <th width="100px" >{{.locale.Tr "admin.users.created"}}</th>
13+ <th>{{.locale.Tr "admin.users.created"}}</th>
1414 <th>{{.locale.Tr "admin.notices.op"}}</th>
1515 </tr>
1616 </thead>
1717 <tbody>
1818 {{range .Notices}}
1919 <tr>
20- <td class="collapsing">
21- <div class="ui fitted checkbox" data-id="{{.ID}}">
22- <input type="checkbox">
23- </div>
24- </td>
20+ <td><div class="ui checkbox gt-db" data-id="{{.ID}}"><input type="checkbox"></div></td>
2521 <td>{{.ID}}</td>
2622 <td>{{$.locale.Tr .TrStr}}</td>
27- <td class="view-detail" ><span class="notice-description text ">{{.Description}}</span></td>
28- <td>{{DateTime "short" .CreatedUnix}}</td>
29- <td><a href="#">{{svg "octicon-note" 16 "view-detail" }}</a></td>
23+ <td class="view-detail auto-ellipsis" style="width: 80%;" ><span class="notice-description">{{.Description}}</span></td>
24+ <td nowrap >{{DateTime "short" .CreatedUnix}}</td>
25+ <td class="view-detail" ><a href="#">{{svg "octicon-note" 16}}</a></td>
3026 </tr>
3127 {{end}}
3228 </tbody>
Original file line number Diff line number Diff line change 6060 white-space : pre-wrap;
6161 word-wrap : break-word;
6262}
63-
64- @media (max-width : 767px ) {
65- .admin # notice-table .notice-description {
66- max-width : 80vw ;
67- }
68- }
69-
70- @media (min-width : 768px ) and (max-width : 991px ) {
71- .admin # notice-table .notice-description {
72- max-width : 360px ;
73- }
74- }
75-
76- @media (min-width : 992px ) and (max-width : 1200px ) {
77- .admin # notice-table .notice-description {
78- max-width : 510px ;
79- }
80- }
81-
82- @media (min-width : 1201px ) {
83- .admin # notice-table .notice-description {
84- max-width : 640px ;
85- }
86- }
Original file line number Diff line number Diff line change 22Gitea's tailwind-style CSS helper classes have `gt-` prefix.
33Gitea's private styles use `g-` prefix.
44*/
5+ .gt-db { display : block !important ; }
56.gt-df { display : flex !important ; }
67.gt-di { display : inline !important ; }
78.gt-dif { display : inline-flex !important ; }
@@ -42,6 +43,23 @@ Gitea's private styles use `g-` prefix.
4243 text-overflow : ellipsis !important ;
4344}
4445
46+
47+ .g-table-auto-ellipsis td .auto-ellipsis {
48+ position : relative;
49+ }
50+
51+ .g-table-auto-ellipsis td .auto-ellipsis span {
52+ position : absolute;
53+ left : 0 ;
54+ right : 0 ;
55+ top : 0 ;
56+ bottom : 0 ;
57+ padding : inherit;
58+ white-space : nowrap;
59+ overflow : hidden;
60+ text-overflow : ellipsis;
61+ }
62+
4563/* below class names match Tailwind CSS */
4664.gt-break-all { word-break : break-all !important ; }
4765.gt-content-center { align-content : center !important ; }
You can’t perform that action at this time.
0 commit comments