virtual_sms 0.2.0 → 0.3.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 9f746f13175d7a032ef7b06e1bf0b8666d8ff9da
4
- data.tar.gz: 0f6d60f78d7cb6df04416fd96094ceff8f69d715
2
+ SHA256:
3
+ metadata.gz: f95f172a4bb7633e34dc37b6241dbee4855d45bd2e17db2c8fa297ed86418d6b
4
+ data.tar.gz: 26142a5512e90611ceb663e550e95b19f6ffbba07f75e8222e3cd579712e13c5
5
5
  SHA512:
6
- metadata.gz: 48b3523ce23e41befca49c815656caae083d9352c75075b79ad54d53c27bcc30eb031fe722857a7be4ea1140f5b7d581383e76ee9bf1738a72281c4292a53980
7
- data.tar.gz: 6f5301efa9d067f7cf8d6aa8c5f325c637641826bb806a1b8aad505fc76bbabcb4fa777fa3fbc0048bdc02888ab861f6371856fe7a0ac13f4bce9e3459e5aef1
6
+ metadata.gz: e9984f9935c65bf5c3453db4dbebbbea112bb83330d48db605537242c75ebf379b8242cccdce8e65d7f92509d82dec53c426fed4747967f79d55b47ce3df3947
7
+ data.tar.gz: db7a33b7e2c4b875dfafb6009da365444199b4193bf1b458935b18c067c506508f635174e309dd658fc2a6e412e63986cba082a589108bcf0d6539fcb79ad81d
data/CHANGELOG.md CHANGED
@@ -1,8 +1,16 @@
1
- # v0.1.1 / 2015-10-28
1
+ # v0.3.0 / 2025-05-04
2
+ ## Changed
3
+ - remove assets dependencies.
2
4
 
3
- * Prevent delivery_method changed.
4
- * Add date column.
5
+ # v0.2.0 / 2020-06-05
6
+ ## Changed
7
+ - Change cache method to support Rails 5+
5
8
 
6
- # v0.1.0 / 2015-10-26
9
+ # v0.1.1 / 2015-10-28
10
+ ## Fixed
11
+ - Prevent delivery_method changed.
12
+ - Add date column.
7
13
 
8
- Create project
14
+ # v0.1.0 / 2015-10-26
15
+ ## Added
16
+ - Create project
@@ -15,7 +15,7 @@ module VirtualSms
15
15
 
16
16
  def clear
17
17
  VirtualSms::Message.clear
18
- redirect_to messages_path
18
+ head :ok
19
19
  end
20
20
 
21
21
  private
@@ -4,8 +4,7 @@
4
4
  <title>
5
5
  Virtual SMS Box
6
6
  </title>
7
- <%= stylesheet_link_tag "virtual_sms/application", media: "all", "data-turbolinks-track" => true %>
8
- <%= javascript_include_tag "virtual_sms/application", "data-turbolinks-track" => true %>
7
+ <%= render "layouts/virtual_sms/styles/application" %>
9
8
  <%= csrf_meta_tags %>
10
9
  </head>
11
10
  <body>
@@ -13,5 +12,6 @@
13
12
  <%= link_to 'Virtual SMS Box', messages_path %>
14
13
  </h2>
15
14
  <%= yield %>
15
+ <%= render "layouts/virtual_sms/javascripts/application" %>
16
16
  </body>
17
17
  </html>
@@ -0,0 +1,19 @@
1
+ <script>
2
+ function clearMessages() {
3
+ if (!confirm('Are you sure you want to clear all messages?')) {
4
+ return;
5
+ }
6
+
7
+ var csrfTokenElement = document.querySelector('meta[name="csrf-token"]');
8
+ var csrfToken = csrfTokenElement ? csrfTokenElement.content : null;
9
+
10
+ fetch('clear', {
11
+ method: 'DELETE',
12
+ headers: {
13
+ 'X-CSRF-Token': csrfToken
14
+ }
15
+ }).then(function() {
16
+ location.reload();
17
+ });
18
+ }
19
+ </script>
@@ -1,24 +1,4 @@
1
- /*
2
- * This is a manifest file that'll be compiled into application.css, which will include all the files
3
- * listed below.
4
- *
5
- * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
6
- * or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
7
- *
8
- * You're free to add application-wide styles to this file and they'll appear at the bottom of the
9
- * compiled file so the styles you add here take precedence over styles defined in any styles
10
- * defined in the other CSS/SCSS files in this directory. It is generally better to create a new
11
- * file per style scope.
12
- *
13
- *= require_tree .
14
- *= require_self
15
- */
16
-
17
- /* http://meyerweb.com/eric/tools/css/reset/
18
- v2.0 | 20110126
19
- License: none (public domain)
20
- */
21
-
1
+ <style>
22
2
  html, body, div, span, applet, object, iframe,
23
3
  h1, h2, h3, h4, h5, h6, p, blockquote, pre,
24
4
  a, abbr, acronym, address, big, cite, code,
@@ -28,8 +8,8 @@ b, u, i, center,
28
8
  dl, dt, dd, ol, ul, li,
29
9
  fieldset, form, label, legend,
30
10
  table, caption, tbody, tfoot, thead, tr, th, td,
31
- article, aside, canvas, details, embed,
32
- figure, figcaption, footer, header, hgroup,
11
+ article, aside, canvas, details, embed,
12
+ figure, figcaption, footer, header, hgroup,
33
13
  menu, nav, output, ruby, section, summary,
34
14
  time, mark, audio, video {
35
15
  margin: 0;
@@ -40,7 +20,7 @@ time, mark, audio, video {
40
20
  vertical-align: baseline;
41
21
  }
42
22
  /* HTML5 display-role reset for older browsers */
43
- article, aside, details, figcaption, figure,
23
+ article, aside, details, figcaption, figure,
44
24
  footer, header, hgroup, menu, nav, section {
45
25
  display: block;
46
26
  }
@@ -111,3 +91,4 @@ a {
111
91
  text-decoration: none;
112
92
  color: #007CFF;
113
93
  }
94
+ </style>
@@ -1,10 +1,10 @@
1
- <%= link_to 'Clear', clear_messages_path, :method => :delete, :data => {:confirm => "Are you sure?"} %>
1
+ <a href="javascript: clearMessages()" >Clear</a>
2
2
  <table>
3
3
  <colgroup>
4
- <col width="250px"></col>
5
- <col width="300px"></col>
6
- <col></col>
7
- <col width="200px"></col>
4
+ <col width="250px" />
5
+ <col width="300px" />
6
+ <col />
7
+ <col width="200px" />
8
8
  </colgroup>
9
9
  <tr>
10
10
  <th>From</th>
@@ -1,3 +1,3 @@
1
1
  module VirtualSms
2
- VERSION = "0.2.0"
2
+ VERSION = "0.3.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: virtual_sms
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chen Yi-Cyuan
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-06-05 00:00:00.000000000 Z
11
+ date: 2025-05-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -39,13 +39,13 @@ dependencies:
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
41
  - !ruby/object:Gem::Dependency
42
- name: jquery-rails
42
+ name: sqlite3
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: '0'
48
- type: :runtime
48
+ type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
@@ -53,7 +53,7 @@ dependencies:
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0'
55
55
  - !ruby/object:Gem::Dependency
56
- name: sqlite3
56
+ name: bundler
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - ">="
@@ -66,34 +66,20 @@ dependencies:
66
66
  - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
- - !ruby/object:Gem::Dependency
70
- name: bundler
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - "~>"
74
- - !ruby/object:Gem::Version
75
- version: '1.10'
76
- type: :development
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - "~>"
81
- - !ruby/object:Gem::Version
82
- version: '1.10'
83
69
  - !ruby/object:Gem::Dependency
84
70
  name: rake
85
71
  requirement: !ruby/object:Gem::Requirement
86
72
  requirements:
87
- - - "~>"
73
+ - - ">="
88
74
  - !ruby/object:Gem::Version
89
- version: '10.0'
75
+ version: '0'
90
76
  type: :development
91
77
  prerelease: false
92
78
  version_requirements: !ruby/object:Gem::Requirement
93
79
  requirements:
94
- - - "~>"
80
+ - - ">="
95
81
  - !ruby/object:Gem::Version
96
- version: '10.0'
82
+ version: '0'
97
83
  - !ruby/object:Gem::Dependency
98
84
  name: rspec-rails
99
85
  requirement: !ruby/object:Gem::Requirement
@@ -162,12 +148,12 @@ files:
162
148
  - LICENSE.txt
163
149
  - README.md
164
150
  - Rakefile
165
- - app/assets/javascripts/virtual_sms/application.js
166
- - app/assets/stylesheets/virtual_sms/application.css
167
151
  - app/controllers/virtual_sms/application_controller.rb
168
152
  - app/controllers/virtual_sms/messages_controller.rb
169
153
  - app/models/virtual_sms/message.rb
170
154
  - app/views/layouts/virtual_sms/application.erb
155
+ - app/views/layouts/virtual_sms/javascripts/_application.html.erb
156
+ - app/views/layouts/virtual_sms/styles/_application.html.erb
171
157
  - app/views/virtual_sms/messages/index.html.erb
172
158
  - app/views/virtual_sms/messages/show.html.erb
173
159
  - config/routes.rb
@@ -181,7 +167,7 @@ homepage: https://github.com/emn178/virtual_sms
181
167
  licenses:
182
168
  - MIT
183
169
  metadata: {}
184
- post_install_message:
170
+ post_install_message:
185
171
  rdoc_options: []
186
172
  require_paths:
187
173
  - lib
@@ -196,9 +182,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
196
182
  - !ruby/object:Gem::Version
197
183
  version: '0'
198
184
  requirements: []
199
- rubyforge_project:
200
- rubygems_version: 2.6.14
201
- signing_key:
185
+ rubygems_version: 3.1.6
186
+ signing_key:
202
187
  specification_version: 4
203
188
  summary: An rails plugin that provides a virtual SMS box and SMS Carrier delivery
204
189
  method.
@@ -1,15 +0,0 @@
1
- // This is a manifest file that'll be compiled into application.js, which will include all the files
2
- // listed below.
3
- //
4
- // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
5
- // or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
6
- //
7
- // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
8
- // compiled file.
9
- //
10
- // Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
11
- // about supported directives.
12
- //
13
- //= require jquery
14
- //= require jquery_ujs
15
- //= require_tree .