plug 0.1.15 → 0.1.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -7,4 +7,4 @@
7
7
  = javascript_include_tag 'plug/application'
8
8
  = csrf_meta_tags
9
9
 
10
- %script{ defer: '', src: 'https://use.fontawesome.com/releases/v5.0.4/js/all.js' }
10
+ %script{ defer: '', src: 'https://use.fontawesome.com/releases/v5.13.0/js/all.js' }
@@ -1,7 +1,7 @@
1
1
  %nav.clearfix.nav
2
2
  .float-left
3
3
  %h3
4
- = link_to 'Plug', plug.root_path, class: 'nav__logo'
4
+ = link_to 'plug', plug.root_path, class: 'nav__logo'
5
5
  %small /unplug features
6
6
  .float-right
7
7
  %ul.menu
@@ -11,10 +11,14 @@
11
11
  = f.text_field :name
12
12
  .field
13
13
  = f.label :notice
14
- = f.text_area :notice, rows: 10
14
+ = f.hidden_field :notice
15
+ %trix-editor{ input: 'site_notice_notice' }
15
16
  .field
16
17
  = f.label :state
17
18
  = f.select :state, ['enabled', 'disabled']
19
+ .field
20
+ = f.label :theme
21
+ = f.select :theme, Plug.themes
18
22
  .actions.clearfix
19
23
  .float-left
20
24
  = link_to 'Back', site_notices_path, class: 'button'
@@ -15,10 +15,10 @@
15
15
  %table
16
16
  %thead
17
17
  %tr
18
- %th Name
18
+ %th{ width: 200 } Name
19
19
  %th Notice
20
- %th Slug
21
- %th State
20
+ %th{ width: 200 } Slug
21
+ %th{ width: 150, align: 'center' } State
22
22
 
23
23
  - if Plug.allow_delete
24
24
  %th Actions
@@ -27,13 +27,13 @@
27
27
  - @site_notices.each do |site_notice|
28
28
  %tr
29
29
  %td= link_to site_notice.name, edit_site_notice_path(site_notice), class: 'strong'
30
- %td= site_notice.notice
30
+ %td= site_notice.notice.html_safe
31
31
  %td= site_notice.slug
32
- %td
32
+ %td{ width: 150, align: 'center' }
33
33
  - if site_notice.state == 'enabled'
34
- %i.fas.fa-check-circle.fa-2x.state__enabled
34
+ %i.fas.fa-check-circle.fa-2x.state.state--enabled
35
35
  - else
36
- %i.fas.fa-times-circle.fa-2x.state__disabled
36
+ %i.fas.fa-times-circle.fa-2x.state.state--disabled
37
37
 
38
38
  - if Plug.allow_delete
39
39
  %td= link_to 'Destroy', site_notice, method: :delete, data: { confirm: 'Are you sure?' }
@@ -0,0 +1,5 @@
1
+ class AddThemeToPlugSiteNotice < ActiveRecord::Migration[5.1]
2
+ def change
3
+ add_column :plug_site_notices, :theme, :string
4
+ end
5
+ end
@@ -3,4 +3,5 @@
3
3
  Plug.configure do |config|
4
4
  config.auth_user = 'admin'
5
5
  config.auth_password = 'password'
6
+ config.themes = ['default', 'dark']
6
7
  end
@@ -9,7 +9,8 @@ module Plug
9
9
  :auth_password,
10
10
  :allow_delete,
11
11
  :buttons,
12
- :api_path
12
+ :api_path,
13
+ :themes
13
14
  ].freeze
14
15
 
15
16
  attr_accessor *VALID_OPTIONS_KEYS
@@ -1,3 +1,3 @@
1
1
  module Plug
2
- VERSION = '0.1.15'
2
+ VERSION = '0.1.22'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: plug
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.15
4
+ version: 0.1.22
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ben
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2018-04-06 00:00:00.000000000 Z
12
+ date: 2020-06-09 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails
@@ -208,6 +208,7 @@ files:
208
208
  - app/assets/images/favicon.png
209
209
  - app/assets/javascripts/plug/application.js
210
210
  - app/assets/javascripts/plug/features.js
211
+ - app/assets/javascripts/plug/trix-core.js
211
212
  - app/assets/stylesheets/plug/_settings.scss
212
213
  - app/assets/stylesheets/plug/application.scss
213
214
  - app/assets/stylesheets/plug/blocks/_alert.scss
@@ -222,6 +223,8 @@ files:
222
223
  - app/assets/stylesheets/plug/normalize.scss
223
224
  - app/assets/stylesheets/plug/partials/_main.scss
224
225
  - app/assets/stylesheets/plug/partials/_utils.scss
226
+ - app/assets/stylesheets/plug/trix-overrides.scss
227
+ - app/assets/stylesheets/plug/trix.scss
225
228
  - app/assets/stylesheets/plug/variables/_colors.scss
226
229
  - app/assets/stylesheets/plug/variables/_typography.scss
227
230
  - app/controllers/plug/api/api_controller.rb
@@ -236,6 +239,7 @@ files:
236
239
  - app/models/plug/feature.rb
237
240
  - app/models/plug/resources/site_notice.rb
238
241
  - app/models/plug/site_notice.rb
242
+ - app/services/plug/task_execution_service.rb
239
243
  - app/views/layouts/plug/application.html.haml
240
244
  - app/views/plug/features/_form.html.haml
241
245
  - app/views/plug/features/_task.html.haml
@@ -252,6 +256,7 @@ files:
252
256
  - db/migrate/20171207020316_create_plug_features.rb
253
257
  - db/migrate/20180128202026_add_notice_to_plug_features.rb
254
258
  - db/migrate/20180403024712_create_plug_site_notices.rb
259
+ - db/migrate/20180424015828_add_theme_to_plug_site_notice.rb
255
260
  - lib/generators/plug/install_generator.rb
256
261
  - lib/generators/plug/templates/plug.rb
257
262
  - lib/plug.rb
@@ -279,8 +284,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
279
284
  - !ruby/object:Gem::Version
280
285
  version: '0'
281
286
  requirements: []
282
- rubyforge_project:
283
- rubygems_version: 2.6.13
287
+ rubygems_version: 3.0.3
284
288
  signing_key:
285
289
  specification_version: 4
286
290
  summary: Rails engine that can plug/unplug features