rush_job 0.2.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +3 -2
- data/app/assets/config/rush_job_manifest.js +0 -1
- data/app/assets/images/rush_job/{arrow-down.svg → arrow-down-dark.svg} +1 -1
- data/app/assets/images/rush_job/arrow-down-light.svg +3 -0
- data/app/assets/images/rush_job/{arrow-up.svg → arrow-up-dark.svg} +1 -1
- data/app/assets/images/rush_job/arrow-up-light.svg +3 -0
- data/app/assets/stylesheets/rush_job/application.scss +2 -0
- data/app/assets/stylesheets/rush_job/pages/_index.scss +12 -0
- data/app/assets/stylesheets/rush_job/themes/_dark.scss +3 -0
- data/app/assets/stylesheets/rush_job/themes/_light.scss +3 -0
- data/app/controllers/rush_job/themes_controller.rb +13 -0
- data/app/helpers/rush_job/application_helper.rb +7 -0
- data/app/helpers/rush_job/rush_jobs_helper.rb +4 -3
- data/app/views/layouts/rush_job/application.html.erb +1 -1
- data/app/views/rush_job/rush_jobs/index.html.erb +11 -5
- data/config/importmap.rb +2 -1
- data/config/routes.rb +1 -0
- data/lib/rush_job/engine.rb +4 -3
- data/lib/rush_job/version.rb +1 -1
- data/vendor/stylesheets/rush_job/bootstrap.css +12273 -0
- metadata +10 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 62c92632ff547f79e44137da7c5d1fa32abebf73e193e415704b04bd981d6256
|
4
|
+
data.tar.gz: 2bb2cbb6fbd881c7c9419ffdb0b9bbe3ace33d3077f44ef3ee5ff1b4c08df6c3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5ab20e3517d870afec5c08873854ed7191daae8efb8b462537d1f04545f2ce7b49ec57a0d3996ac2efa7246a5073e856b19d7420006708bd4d6dd2f369f4a9dd
|
7
|
+
data.tar.gz: 40421bf79367edd3e4ee1b4211adae3e9e918c69a76203cc2468c5779a6d19169b832d56cb9ce672cd8694b09f3f23df83e82aac6c5e5dd4c71bf59eac586925
|
data/README.md
CHANGED
@@ -2,7 +2,8 @@
|
|
2
2
|
User interface for Delayed Job (https://github.com/collectiveidea/delayed_job) in Ruby on Rails
|
3
3
|
|
4
4
|
### Note
|
5
|
-
This has only been tested with SQLite and Postgresql.
|
5
|
+
- This has only been tested with SQLite and Postgresql.
|
6
|
+
- This app uses cookies to store the dark mode selection.
|
6
7
|
|
7
8
|
## Usage
|
8
9
|
You will need Delayed Job, `delayed_job`, and Delayed Job ActiveRecord, `delayed_job_active_record`, installed in a Ruby on Rails application for this gem to work properly.
|
@@ -13,7 +14,7 @@ Navigate to the `/rush_job` route in your application to see the Delayed Jobs. L
|
|
13
14
|
Add this line to your Ruby on Rails application's Gemfile:
|
14
15
|
|
15
16
|
```ruby
|
16
|
-
gem
|
17
|
+
gem 'rush_job', '~> 0.3.1'
|
17
18
|
```
|
18
19
|
|
19
20
|
And then execute:
|
@@ -1,3 +1,3 @@
|
|
1
|
-
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="rgb(0, 0, 0)" class="bi bi-arrow-down" viewBox="0 0 16 16">
|
2
2
|
<path fill-rule="evenodd" d="M8 1a.5.5 0 0 1 .5.5v11.793l3.146-3.147a.5.5 0 0 1 .708.708l-4 4a.5.5 0 0 1-.708 0l-4-4a.5.5 0 0 1 .708-.708L7.5 13.293V1.5A.5.5 0 0 1 8 1z"/>
|
3
3
|
</svg>
|
@@ -0,0 +1,3 @@
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="rgb(255, 255, 255)" class="bi bi-arrow-down" viewBox="0 0 16 16">
|
2
|
+
<path fill-rule="evenodd" d="M8 1a.5.5 0 0 1 .5.5v11.793l3.146-3.147a.5.5 0 0 1 .708.708l-4 4a.5.5 0 0 1-.708 0l-4-4a.5.5 0 0 1 .708-.708L7.5 13.293V1.5A.5.5 0 0 1 8 1z"/>
|
3
|
+
</svg>
|
@@ -1,3 +1,3 @@
|
|
1
|
-
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="rgb(0, 0, 0)" class="bi bi-arrow-up" viewBox="0 0 16 16">
|
2
2
|
<path fill-rule="evenodd" d="M8 15a.5.5 0 0 0 .5-.5V2.707l3.146 3.147a.5.5 0 0 0 .708-.708l-4-4a.5.5 0 0 0-.708 0l-4 4a.5.5 0 1 0 .708.708L7.5 2.707V14.5a.5.5 0 0 0 .5.5z"/>
|
3
3
|
</svg>
|
@@ -0,0 +1,3 @@
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="rgb(255, 255, 255)" class="bi bi-arrow-up" viewBox="0 0 16 16">
|
2
|
+
<path fill-rule="evenodd" d="M8 15a.5.5 0 0 0 .5-.5V2.707l3.146 3.147a.5.5 0 0 0 .708-.708l-4-4a.5.5 0 0 0-.708 0l-4 4a.5.5 0 1 0 .708.708L7.5 2.707V14.5a.5.5 0 0 0 .5.5z"/>
|
3
|
+
</svg>
|
@@ -20,4 +20,16 @@
|
|
20
20
|
margin-left: 5%;
|
21
21
|
margin-right: 5%;
|
22
22
|
float: right;
|
23
|
+
}
|
24
|
+
|
25
|
+
.page-link.disabled, .disabled > .page-link {
|
26
|
+
color: rgb(68, 110, 155);
|
27
|
+
}
|
28
|
+
|
29
|
+
.page-item:first-child .page-link {
|
30
|
+
color: rgb(68, 110, 155);
|
31
|
+
}
|
32
|
+
|
33
|
+
.page-item:last-child .page-link {
|
34
|
+
color: rgb(68, 110, 155);
|
23
35
|
}
|
@@ -1,20 +1,21 @@
|
|
1
1
|
module RushJob
|
2
2
|
module RushJobsHelper
|
3
|
+
include ApplicationHelper
|
3
4
|
include SortHelper
|
4
5
|
include Pagy::Frontend
|
5
6
|
|
6
7
|
def sortable(column)
|
7
8
|
direction = column == sort_column && sort_direction == 'asc' ? 'desc' : 'asc'
|
8
|
-
link_to t(column), rush_job.root_path({ sort: column, direction: })
|
9
|
+
link_to t(column), rush_job.root_path({ sort: column, direction: }), class: "link-#{invert_theme}"
|
9
10
|
end
|
10
11
|
|
11
12
|
def sort_arrow(column)
|
12
13
|
return unless column == sort_column
|
13
14
|
|
14
15
|
if sort_direction == 'desc'
|
15
|
-
image_tag(
|
16
|
+
image_tag("rush_job/arrow-down-#{invert_theme}.svg", id: 'rush-job-down-arrow', alt: 'down arrow')
|
16
17
|
else
|
17
|
-
image_tag(
|
18
|
+
image_tag("rush_job/arrow-up-#{invert_theme}.svg", id: 'rush-job-up-arrow', alt: 'up arrow')
|
18
19
|
end
|
19
20
|
end
|
20
21
|
end
|
@@ -1,12 +1,12 @@
|
|
1
|
-
<div class="header-container">
|
1
|
+
<div class="header-container" role="heading" aria-level="1">
|
2
2
|
<div class="container text-center">
|
3
3
|
<div class="row align-items-center">
|
4
|
-
<div class="col-6">
|
4
|
+
<div class="col-6" role="banner">
|
5
5
|
<h2 class="delayed_title">
|
6
6
|
<%= t :delayed_title %>
|
7
7
|
</h2>
|
8
8
|
</div>
|
9
|
-
<div class="col-
|
9
|
+
<div class="col-3">
|
10
10
|
<button
|
11
11
|
type="button"
|
12
12
|
class="btn btn-primary"
|
@@ -14,15 +14,21 @@
|
|
14
14
|
<%= t :reload %>
|
15
15
|
</button>
|
16
16
|
</div>
|
17
|
+
<div class="col-3">
|
18
|
+
<%= form_with url: theme_path, method: 'patch' do |form| %>
|
19
|
+
<%= form.button "#{invert_theme.titleize} Mode", class: "btn btn-#{invert_theme}" %>
|
20
|
+
<% end %>
|
21
|
+
</div>
|
17
22
|
</div>
|
18
23
|
</div>
|
19
24
|
</div>
|
20
25
|
|
21
|
-
<div class="jobs-container">
|
26
|
+
<div class="jobs-container" role="main">
|
22
27
|
<div class="table-responsive">
|
23
28
|
<table class="table
|
24
29
|
table-bordered
|
25
|
-
table-striped
|
30
|
+
table-striped
|
31
|
+
table-<%= current_theme %>">
|
26
32
|
<thead>
|
27
33
|
<tr>
|
28
34
|
<th><%= sortable 'id' %><%= sort_arrow 'id' %></th>
|
data/config/importmap.rb
CHANGED
@@ -1,2 +1,3 @@
|
|
1
1
|
pin 'rush_job/application', preload: true
|
2
|
-
pin 'bootstrap', to: '
|
2
|
+
pin 'bootstrap', to: 'https://ga.jspm.io/npm:bootstrap@5.3.1/dist/js/bootstrap.esm.js'
|
3
|
+
pin '@popperjs/core', to: 'https://ga.jspm.io/npm:@popperjs/core@2.11.8/lib/index.js'
|
data/config/routes.rb
CHANGED
data/lib/rush_job/engine.rb
CHANGED
@@ -17,9 +17,10 @@ module RushJob
|
|
17
17
|
rush_job/application.css
|
18
18
|
rush_job/application.scss
|
19
19
|
rush_job/application.js
|
20
|
-
rush_job/arrow-up.svg
|
21
|
-
rush_job/arrow-
|
22
|
-
rush_job/
|
20
|
+
rush_job/arrow-up-light.svg
|
21
|
+
rush_job/arrow-up-dark.svg
|
22
|
+
rush_job/arrow-down-light.svg
|
23
|
+
rush_job/arrow-down-dark.svg
|
23
24
|
rush_job_manifest.js
|
24
25
|
]
|
25
26
|
end
|
data/lib/rush_job/version.rb
CHANGED