Skip to content

Commit

Permalink
Merge pull request #519 from matestack/next_release
Browse files Browse the repository at this point in the history
1.4 Release
  • Loading branch information
jonasjabari authored Feb 5, 2021
2 parents 829eb2f + a1d7005 commit f86127c
Show file tree
Hide file tree
Showing 39 changed files with 836 additions and 177 deletions.
23 changes: 23 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
node_modules/
spec/dummy/db/*.sqlite3
spec/dummy/db/*.sqlite3-journal
spec/dummy/log/*.log
spec/dummy/node_modules/
spec/dummy/public/packs/
spec/dummy/public/packs-test/
spec/dummy/yarn-error.log
spec/dummy/storage/
spec/dummy/tmp/
builder/db/*.sqlite3
builder/db/*.sqlite3-journal
builder/log/*.log
builder/node_modules/
builder/yarn-error.log
builder/storage/
builder/tmp/
builder/public/packs
.idea/
.vscode
.byebug_history

/coverage
56 changes: 51 additions & 5 deletions .github/workflows/dockerpush.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,59 @@ name: specs
on: [push]

jobs:
test:
test_6_1_ruby_3_0:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Run tests
run: |
docker-compose -f ./ci/docker-compose.ci.yml run --rm test_6_1_ruby_3_0
- name: Upload lock files
uses: actions/upload-artifact@v2
with:
name: lockfiles_test_6_1_ruby_3_0
path: |
./ci/artifacts/yarn.lock
./ci/artifacts/Gemfile.lock
test_6_1_ruby_2_7:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Run tests
run: |
docker-compose -f ./ci/docker-compose.ci.yml run --rm test_6_1_ruby_2_7
- name: Upload lock files
uses: actions/upload-artifact@v2
with:
name: lockfiles_test_6_1_ruby_2_7
path: |
./ci/artifacts/yarn.lock
./ci/artifacts/Gemfile.lock
test_6_0_ruby_2_6:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Run tests
run: |
docker-compose -f ./ci/docker-compose.ci.yml run --rm test_6_0_ruby_2_6
- name: Upload lock files
uses: actions/upload-artifact@v2
with:
name: lockfiles_test_6_0_ruby_2_6
path: |
./ci/artifacts/yarn.lock
./ci/artifacts/Gemfile.lock
test_5_2_ruby_2_6:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Run tests
run: |
docker-compose run --rm test bundle exec rake db:schema:load
docker-compose run --rm test bundle exec rspec spec/test
docker-compose -f ./ci/docker-compose.ci.yml run --rm test_5_2_ruby_2_6
- name: Upload lock files
uses: actions/upload-artifact@v2
with:
name: lockfiles_test_5_2_ruby_2_6
path: |
./ci/artifacts/yarn.lock
./ci/artifacts/Gemfile.lock
18 changes: 18 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,23 @@
# Changelog

## v1.4.0 Release - 2021-02-05

### Improvements

- Ruby 3 support
- Vue update to 2.6.12
- Vuex update to 3.6.2
- Gemspec update clarifying that Rails below 5.2 is not supported (EOL versions anyway!)
- CI test runs against multiple Rails/Ruby version combination

### Bugfixes

- Webpacker 6 support #500

### Security bumps

- Various version bumps triggered through dependabot

## v1.3.2 Release - 2021-01-11

### Bugfixes
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.test
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ruby:2.7.2-alpine3.12
FROM ruby:3.0-alpine3.12

RUN gem install bundler:2.1.4

Expand Down
130 changes: 66 additions & 64 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,66 +1,66 @@
PATH
remote: .
specs:
matestack-ui-core (1.0.1)
cells-haml
cells-rails
haml
rails (>= 5.0)
trailblazer-cells
matestack-ui-core (1.3.2)
cells-haml (>= 0.0.10)
cells-rails (>= 0.1.0)
haml (>= 4.1.0.beta.1)
rails (>= 5.2)
trailblazer-cells (>= 0.0.3)

GEM
remote: https://rubygems.org/
specs:
actioncable (6.0.3.3)
actionpack (= 6.0.3.3)
actioncable (6.0.3.2)
actionpack (= 6.0.3.2)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
actionmailbox (6.0.3.3)
actionpack (= 6.0.3.3)
activejob (= 6.0.3.3)
activerecord (= 6.0.3.3)
activestorage (= 6.0.3.3)
activesupport (= 6.0.3.3)
actionmailbox (6.0.3.2)
actionpack (= 6.0.3.2)
activejob (= 6.0.3.2)
activerecord (= 6.0.3.2)
activestorage (= 6.0.3.2)
activesupport (= 6.0.3.2)
mail (>= 2.7.1)
actionmailer (6.0.3.3)
actionpack (= 6.0.3.3)
actionview (= 6.0.3.3)
activejob (= 6.0.3.3)
actionmailer (6.0.3.2)
actionpack (= 6.0.3.2)
actionview (= 6.0.3.2)
activejob (= 6.0.3.2)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
actionpack (6.0.3.3)
actionview (= 6.0.3.3)
activesupport (= 6.0.3.3)
actionpack (6.0.3.2)
actionview (= 6.0.3.2)
activesupport (= 6.0.3.2)
rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
actiontext (6.0.3.3)
actionpack (= 6.0.3.3)
activerecord (= 6.0.3.3)
activestorage (= 6.0.3.3)
activesupport (= 6.0.3.3)
actiontext (6.0.3.2)
actionpack (= 6.0.3.2)
activerecord (= 6.0.3.2)
activestorage (= 6.0.3.2)
activesupport (= 6.0.3.2)
nokogiri (>= 1.8.5)
actionview (6.0.3.3)
activesupport (= 6.0.3.3)
actionview (6.0.3.2)
activesupport (= 6.0.3.2)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
activejob (6.0.3.3)
activesupport (= 6.0.3.3)
activejob (6.0.3.2)
activesupport (= 6.0.3.2)
globalid (>= 0.3.6)
activemodel (6.0.3.3)
activesupport (= 6.0.3.3)
activerecord (6.0.3.3)
activemodel (= 6.0.3.3)
activesupport (= 6.0.3.3)
activestorage (6.0.3.3)
actionpack (= 6.0.3.3)
activejob (= 6.0.3.3)
activerecord (= 6.0.3.3)
activemodel (6.0.3.2)
activesupport (= 6.0.3.2)
activerecord (6.0.3.2)
activemodel (= 6.0.3.2)
activesupport (= 6.0.3.2)
activestorage (6.0.3.2)
actionpack (= 6.0.3.2)
activejob (= 6.0.3.2)
activerecord (= 6.0.3.2)
marcel (~> 0.3.1)
activesupport (6.0.3.3)
activesupport (6.0.3.2)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
Expand Down Expand Up @@ -91,7 +91,7 @@ GEM
cells (>= 4.1.6, < 5.0.0)
childprocess (3.0.0)
coderay (1.1.2)
concurrent-ruby (1.1.7)
concurrent-ruby (1.1.6)
crack (0.4.3)
safe_yaml (~> 1.0.0)
crass (1.0.6)
Expand All @@ -110,9 +110,9 @@ GEM
temple (>= 0.8.0)
tilt
hashdiff (1.0.0)
i18n (1.8.5)
i18n (1.8.3)
concurrent-ruby (~> 1.0)
loofah (2.7.0)
loofah (2.6.0)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
mail (2.7.1)
Expand All @@ -122,11 +122,12 @@ GEM
method_source (0.9.2)
mimemagic (0.3.5)
mini_mime (1.0.2)
mini_portile2 (2.4.0)
mini_portile2 (2.5.0)
minitest (5.14.2)
nio4r (2.5.3)
nokogiri (1.10.10)
mini_portile2 (~> 2.4.0)
nokogiri (1.11.1)
mini_portile2 (~> 2.5.0)
racc (~> 1.4)
pg (1.2.3)
pry (0.12.2)
coderay (~> 1.1.0)
Expand All @@ -139,34 +140,35 @@ GEM
public_suffix (4.0.3)
puma (4.3.5)
nio4r (~> 2.0)
racc (1.5.2)
rack (2.2.3)
rack-proxy (0.6.5)
rack
rack-test (1.1.0)
rack (>= 1.0, < 3)
rails (6.0.3.3)
actioncable (= 6.0.3.3)
actionmailbox (= 6.0.3.3)
actionmailer (= 6.0.3.3)
actionpack (= 6.0.3.3)
actiontext (= 6.0.3.3)
actionview (= 6.0.3.3)
activejob (= 6.0.3.3)
activemodel (= 6.0.3.3)
activerecord (= 6.0.3.3)
activestorage (= 6.0.3.3)
activesupport (= 6.0.3.3)
rails (6.0.3.2)
actioncable (= 6.0.3.2)
actionmailbox (= 6.0.3.2)
actionmailer (= 6.0.3.2)
actionpack (= 6.0.3.2)
actiontext (= 6.0.3.2)
actionview (= 6.0.3.2)
activejob (= 6.0.3.2)
activemodel (= 6.0.3.2)
activerecord (= 6.0.3.2)
activestorage (= 6.0.3.2)
activesupport (= 6.0.3.2)
bundler (>= 1.3.0)
railties (= 6.0.3.3)
railties (= 6.0.3.2)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.3.0)
loofah (~> 2.3)
railties (6.0.3.3)
actionpack (= 6.0.3.3)
activesupport (= 6.0.3.3)
railties (6.0.3.2)
actionpack (= 6.0.3.2)
activesupport (= 6.0.3.2)
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
Expand Down Expand Up @@ -209,7 +211,7 @@ GEM
sprockets (4.0.2)
concurrent-ruby (~> 1.0)
rack (> 1, < 3)
sprockets-rails (3.2.1)
sprockets-rails (3.2.2)
actionpack (>= 4.0)
activesupport (>= 4.0)
sprockets (>= 3.0.0)
Expand Down Expand Up @@ -238,7 +240,7 @@ GEM
websocket-extensions (0.1.5)
xpath (3.2.0)
nokogiri (~> 1.8)
zeitwerk (2.4.0)
zeitwerk (2.3.1)

PLATFORMS
ruby
Expand Down
22 changes: 22 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ Reactivity included if desired.

You end up writing 50% less code while increasing productivity, maintainability and developer happiness. Work with pure Ruby. If necessary, extend with pure JavaScript. No Opal involved.

[<img src="https://img.youtube.com/vi/Mue5gs6Wtq4/0.jpg" width="350">](https://www.youtube.com/watch?v=Mue5gs6Wtq4)

The main goals are:

- More maintainable UI code, using a component-based structure written in Ruby
Expand All @@ -25,6 +27,26 @@ The main goals are:
it alongside your classic views and incrementally turn your Rails-App into a
dynamic Web-App.

## Compatibility

### Ruby/Rails

`matestack-ui-core` is tested against:

- Rails 6.1.1 + Ruby 3.0.0
- Rails 6.1.1 + Ruby 2.7.2
- Rails 6.0.3.4 + Ruby 2.6.6
- Rails 5.2.4.4 + Ruby 2.6.6

Rails versions below 5.2 are not supported.

### Vue.js

`matestack-ui-core` currently uses Vue.js 2.6.12 and Vuex 3.6.2 for its reactivity features.
Custom reactive components are bound to these versions as well.

Vue 3 / Vuex 4 update is planned for Q2 2021.

## Documentation/Installation

Documentation can be found [here](https://docs.matestack.io)
Expand Down
8 changes: 7 additions & 1 deletion app/concepts/matestack/ui/core/collection/helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,13 @@ def get_collection_order collection_id, key=nil
end
end

def set_collection id: nil, init_offset: 0, init_limit: nil, base_count: nil, filtered_count: nil, data: nil
# since ruby 3 changed hash <-> keyword argument transformation, we need to
# adjust this method call in order to stay compatible with ruby 2.x and ruby 3.x
def set_collection options_hash
_set_collection **options_hash
end

def _set_collection id: nil, init_offset: 0, init_limit: nil, base_count: nil, filtered_count: nil, data: nil
@collections = {} if @collections.nil?

collection_config = CollectionConfig.new(
Expand Down
4 changes: 2 additions & 2 deletions app/concepts/matestack/ui/core/view/view.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
require_dependency "cell/partial"
require "cell/partial"

module Matestack::Ui::Core::View
class View < Matestack::Ui::Core::Component::Static
Expand All @@ -15,7 +15,7 @@ def include_partial
controller.render_to_string view_path, layout: false, locals: locals
elsif partial_path
controller.render_to_string partial: partial_path, layout: false, locals: locals
else
else
raise 'view or partial param missing for RailsView Component'
end
end
Expand Down
Loading

0 comments on commit f86127c

Please sign in to comment.