Skip to content

Commit 92d1d3d

Browse files
kushthedudeniranjan94
authored andcommitted
fix: Less Table Space Consumption and Fixing Loose Tables on Small Screen (#3042)
* Fixing Irresponsive tables and Loose Headers * Removing extra unstackable class
1 parent 1ca6626 commit 92d1d3d

File tree

5 files changed

+33
-23
lines changed

5 files changed

+33
-23
lines changed

app/templates/components/events/view/overview/event-tickets.hbs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
</div>
44
<div class="content">
55
<h4 class="ui header">{{t 'Summary'}}</h4>
6-
<table class="ui very basic compact table">
6+
<table class="ui very basic compact unstackable table">
77
<tbody>
88
<tr>
99
<td>{{t 'Total tickets sold'}}</td>
@@ -20,7 +20,7 @@
2020
</tbody>
2121
</table>
2222
<h4 class="ui header">{{t 'Details'}}</h4>
23-
<table class="ui very basic compact table">
23+
<table class="ui very basic compact unstackable table">
2424
<thead>
2525
<tr>
2626
<th>{{t 'Type'}}</th>

app/templates/components/events/view/overview/manage-roles.hbs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
<button class="ui {{if (eq roleType 'accepted') 'active'}} button" {{action 'filter' 'accepted'}}>{{t 'Accepted'}}</button>
77
<button class="ui {{if (eq roleType 'pending') 'active'}} button" {{action 'filter' 'pending'}}>{{t 'Invited'}}</button>
88
</div>
9-
<div class="content">
10-
<table class="ui very basic table">
9+
<div class="content x-scrollable">
10+
<table class="ui very basic unstackable table">
1111
<thead>
1212
<tr>
1313
<th>{{t 'User(Email)'}}</th>

app/templates/events.hbs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
{{/tabbed-navigation}}
1919
</div>
2020
</div>
21-
<div class="ui basic segment">
21+
<div class="ui basic segment" style="padding-top: 0">
2222
{{outlet}}
2323
</div>
2424
{{else}}

app/templates/events/view/tickets/index.hbs

Lines changed: 26 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
{{t 'By order status'}}
1818
</span>
1919
</div>
20-
<table class="ui stackable celled table">
20+
<table class="ui stackable celled unstackable table">
2121
<thead>
2222
<tr>
2323
<th>{{t 'Order Status'}}</th>
@@ -120,38 +120,48 @@
120120
</table>
121121
</div>
122122
<br>
123+
123124
<div class="row">
124-
<table class="ui stackable structured celled table">
125+
<table class="ui stackable celled unstackable table">
125126
<thead>
126127
<tr>
127128
<th rowspan="2" class="left aligned">{{t 'Ticket Type'}}</th>
128129
<th rowspan="2" class="left aligned">{{t 'Tickets Capacity Set'}}</th>
129-
<th colspan="2" class="ui green inverted segment center aligned">{{t 'Completed Orders '}}</th>
130-
<th colspan="2" class="ui blue inverted segment center aligned">{{t 'Placed Orders'}}</th>
131-
<th colspan="2" class="ui yellow inverted segment center aligned">{{t 'Pending Orders '}}</th>
132-
</tr>
133-
<tr>
134-
<th class="right aligned">{{t 'Tickets'}}</th>
135-
<th class="right aligned">{{t 'Sales'}}</th>
136-
<th class="right aligned">{{t 'Tickets'}}</th>
137-
<th class="right aligned">{{t 'Sales'}}</th>
138-
<th class="right aligned">{{t 'Tickets'}}</th>
139-
<th class="right aligned">{{t 'Sales'}}</th>
130+
<th colspan="{{if device.isMobile "1" "2"}}" class="ui green inverted segment center aligned">{{if device.isMobile 'Sales ' ''}}{{t 'Completed Orders '}}</th>
131+
<th colspan="{{if device.isMobile "1" "2"}}" class="ui blue inverted segment center aligned">{{if device.isMobile 'Sales ' ''}}{{t 'Placed Orders'}}</th>
132+
<th colspan="{{if device.isMobile "1" "2"}}" class="ui yellow inverted segment center aligned">{{if device.isMobile 'Sales ' ''}}{{t 'Pending Orders '}}</th>
140133
</tr>
134+
{{#unless device.isMobile}}
135+
<tr>
136+
<th class="right aligned">{{t 'Tickets'}}</th>
137+
<th class="right aligned">{{t 'Sales'}}</th>
138+
<th class="right aligned">{{t 'Tickets'}}</th>
139+
<th class="right aligned">{{t 'Sales'}}</th>
140+
<th class="right aligned">{{t 'Tickets'}}</th>
141+
<th class="right aligned">{{t 'Sales'}}</th>
142+
</tr>
143+
{{/unless}}
141144
</thead>
142145
<tbody>
143146
{{#each model.tickets as |ticket|}}
144147
<tr>
145148
<td>{{ticket.name}}</td>
146149
<td>{{ticket.quantity}}</td>
147-
<td class="right aligned">{{ticket.orderStatistics.tickets.completed}}</td>
150+
{{#unless device.isMobile}}
151+
<td class="right aligned">{{ticket.orderStatistics.tickets.completed}}</td>
152+
{{/unless}}
148153
<td class="right aligned">{{currency-symbol model.eventDetail.paymentCurrency}} {{format-number ticket.orderStatistics.sales.completed}}</td>
149-
<td class="right aligned">{{ticket.orderStatistics.tickets.placed}}</td>
154+
{{#unless device.isMobile}}
155+
<td class="right aligned">{{ticket.orderStatistics.tickets.placed}}</td>
156+
{{/unless}}
150157
<td class="right aligned">{{currency-symbol model.eventDetail.paymentCurrency}} {{format-number ticket.orderStatistics.sales.placed}}</td>
151-
<td class="right aligned">{{ticket.orderStatistics.tickets.pending}}</td>
158+
{{#unless device.isMobile}}
159+
<td class="right aligned">{{ticket.orderStatistics.tickets.pending}}</td>
160+
{{/unless}}
152161
<td class="right aligned">{{currency-symbol model.eventDetail.paymentCurrency}} {{format-number ticket.orderStatistics.sales.pending}}</td>
153162
</tr>
154163
{{/each}}
155164
</tbody>
156165
</table>
157166
</div>
167+

app/themes/semantic.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ export default Default.extend({
2020
},
2121

2222
classes: {
23-
outerTableWrapper : 'ui ui-table',
23+
outerTableWrapper : 'ui unstackable ui-table',
2424
innerTableWrapper : 'ui segment column sixteen wide inner-table-wrapper',
25-
table : 'ui very basic table',
25+
table : 'ui very basic unstackable table',
2626
globalFilterWrapper : 'ui row',
2727
columnsDropdownWrapper : 'right floated columns-dropdown',
2828
columnsDropdownButtonWrapper : 'buttons',

0 commit comments

Comments
 (0)