Commit graph

25 commits

Author SHA1 Message Date
Anton Khorev
ed99c62874 Tweak sizes and alignment of traces rss/upload buttons 2023-09-14 21:00:57 +03:00
Anton Khorev
bdb4e025f8 Use start margin instead of empty <li> for gap before traces rss button 2023-09-14 18:02:55 +03:00
Anton Khorev
e143726f1a Combine comments and traces pagination partials 2023-09-09 14:33:59 +03:00
Tom Hughes
c909b29c35 Replace page numbers with ID based selection for trace indexes 2023-07-23 19:28:37 +01:00
Andy Allan
10e035df93 Refactor trace guidance to avoid raw html in translations
Also rearrange to avoid multiple sentences in a heading.
2023-02-22 09:16:17 +00:00
Tom Hughes
297d05c63b Merge remote-tracking branch 'upstream/pull/3610' 2022-07-21 18:36:29 +01:00
Andy Allan
4e06fe054a Rework trace index to use secondary-actions
The border between items is familiar UI, so we can keep it, but lets
use the secondary-actions approach instead.

This avoids using left-right specific border, margin and padding
classes
2022-07-20 17:45:35 +01:00
Andy Allan
9e6ecefdb2 Bootstrap 5: Remove the padding from trace nav buttons on larger sizes
If additional py is added when the tabs are laid out in full, then the
other tabs start to become detatched from the rest of the page and a
line appears under the active tab.

We don't need the padding in the horizontal layout, so remove it, and
tweak the size of the padding when collapsed.
2022-07-20 14:43:00 +01:00
Andy Allan
a32854fa52 Wrap the rss and upload buttons in a div, with suitable padding for both vertical and horizontal tab layouts
This ensures it looks right when the tabs are collapsed vertically.
2021-06-16 17:08:26 +01:00
Andy Allan
81ad715474 Rework tabs to use flexbox
This improves the behaviour on small widths, where the tabs stack neatly. It also avoids the use of ml-auto which isn't RTL compatible.

The change in indentation is because it was previously coded with multiple li nested inside another li
2021-06-16 16:48:23 +01:00
Andy Allan
62349d1856 Make tab labels into nouns that describe what's on the tab
I think that works better with tabs, whereas actions (verbs) work better with buttons.
2021-06-16 16:27:45 +01:00
Andy Allan
7996b84380 Rearrange tabs for inter-page consistency
The all traces tab comes first, since it's shown on every page as you click around. Otherwise the tabs appear to be constantly rearranging themselves.
2021-06-16 16:26:25 +01:00
Michal Migurski
33f9b7c55f Fixed remaining erblint complaint 2021-06-16 15:55:55 +01:00
Michal Migurski
21eafac304 Fix erblint complaints 2021-06-16 15:55:55 +01:00
Tobias Jordans
f4e998804d Traces#index: Introduce tab navigation, fix tag-filter
- introduce bootstrap tabs to switch the views
- introduce `content_for :heading_class` to remove the padding below the bootstrap tabs
- update the rss-image to use a svg, adopted from https://icons.getbootstrap.com/icons/rss/ (without the outer border)
- move rss- and new-button away from the view-switching actions
- the `@tag` logic was broken. introduce new link to remove the tag-filter; the tabs keep the filter once given; use params[:tag] directly in the view
- use `&.` syntax nil-safety so we can remove `@display_name`
2021-06-16 15:55:55 +01:00
Andy Allan
4dc584421a Refactor traces list display
Ideas taken from #3036
2021-03-17 18:04:00 +00:00
Andy Allan
76146baf60 Remove spacing tweaks and legacy pagination spacing CSS
No need to fight against something that we no longer use.
2021-01-06 15:40:53 +00:00
Tobias Jordans
18ec273038 Traces: Migrate pagination to bootstrap
Same feature, different style.
- Change pagination to use bootstrap default styles
- … but with empty span-tags instead of non-active a-tags
- refactor partial to not use @-variables but get the variables via
the render-call, simplify render-call-syntax
- remove the additional `if @traces.size > 1` inside the pagination
partial since that caused the pagination to disappear on the last page.
The partial will be visible with inactive links.
- Add bootstrap spacer-classes to overwrite commons-css so removing. Eg.
commons also has a pagination class same as bootstrap.
2021-01-03 20:55:50 +01:00
Andy Allan
6d9434e14d Remove some extraneous css
The trace part is actually removing html, but I thought it was CSS
when I first noticed the blank space on the page.
2020-07-08 16:57:49 +02:00
Andy Allan
b8c1bbb4f8 Remove unnecessary h() calls on model attributes
These were necessary in the rails 2.x era, but not now.
2020-03-18 14:33:30 +01:00
Andy Allan
5fdada204c Use bootstrap table striping to replace hand-cycled table stripes
This cuts down on the complexity of having to use the `cycle` function
and makes the templates easier to read. CSS-based striping has been
around for many years.

The CSS is in order to keep our custom colour for striped tables.
2020-03-18 12:14:24 +01:00
Andy Allan
7410b59a50 Remove unused trace_optionals partial
Although the code to render the partial runs, `yield :optionals`
was removed from the site layout in 2013. So the code has been
ineffective since then.
2019-10-30 15:02:35 +01:00
Andy Allan
3914050fcc Simplify partial rendering when the partial is named after the model 2019-06-26 14:13:09 +02:00
Tom Hughes
3af16f6337 erblint: fix remaining single quoted strings 2019-03-27 16:15:19 +00:00
Andy Allan
d0089f0ce8 Rename traces#list to traces#index 2018-08-29 17:58:37 +08:00
Renamed from app/views/traces/list.html.erb (Browse further)