mumuki-gobstones-runner 2.2.1 → 2.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8ed154da8beda18cbe74626dad0c7b5b8ad58000451dd9cd1d507da24d0905f5
4
- data.tar.gz: ff4176d1b3dc02bef224ac98fea3888bce0436d17df29e7609464ce832c2efc2
3
+ metadata.gz: f98c514029effaef38c244549744523c2317e834a1c8605157ae6ac064e91750
4
+ data.tar.gz: 8bf1d50de903c8c3945d3d0c4e02b6b4e8868cf09e07d173cf66d5ee2e0aa727
5
5
  SHA512:
6
- metadata.gz: 30abe8471e156c0c2debfc289486df6afd31ccd0a591b66dab910342db97a08e5fd91897f6de161c536db611431eb17d5f71aae726a1743e9c6d27667d0af01c
7
- data.tar.gz: b41b3e8aa4b954c454122861f2933a500efb86e11cd3adcc76d4f3e84af0d1071fd7dd61219b6fabbf7a232bd586dbaf52b9ec567291909ce472e63455e03b04
6
+ metadata.gz: b3aa17c98f86f7ee976022935921d9355df7cd863d516c6d1b538783eea4a72021e4bec5d5e5f907a3c1a38db727c7e126c08c6db7fa60e526cd7fd75bb94940
7
+ data.tar.gz: 0b777db903fd76952d7b994a68afc3645fa10120593af0de17341dfbf28e027d7ac51497c806de257a0c31f589c58feb1a42b30e54910eebf8e9128daacf644a
data/lib/assets_server.rb CHANGED
@@ -1,19 +1,5 @@
1
- require 'sinatra/base'
2
- require 'sinatra/cross_origin'
3
-
4
1
  class Mumukit::Server::App < Sinatra::Base
5
- register Sinatra::CrossOrigin
6
-
7
- configure do
8
- enable :cross_origin
9
- set :allow_origin, '*'
10
- end
11
-
12
- def self.get_asset(route, absolute_path, type)
13
- get "/assets/#{route}" do
14
- send_file absolute_path, type: type
15
- end
16
- end
2
+ include Mumukit::Server::WithAssets
17
3
 
18
4
  def self.get_board_asset(route, path, type)
19
5
  get_asset route, Gobstones::Board.assets_path_for(path), type
@@ -27,10 +13,6 @@ class Mumukit::Server::App < Sinatra::Base
27
13
  get_asset route, Gobstones::CodeRunner.assets_path_for(path), type
28
14
  end
29
15
 
30
- def self.get_local_asset(route, path, type)
31
- get_asset route, File.join(__dir__, '..', path), type
32
- end
33
-
34
16
  ['polymer', 'polymer-mini', 'polymer-micro'].each { |name|
35
17
  get_board_asset "#{name}.html", "htmls/vendor/#{name}.html", 'text/html'
36
18
  }
@@ -5,7 +5,7 @@ I18n.load_translations_path File.join(__dir__, 'locales', '*.yml')
5
5
 
6
6
  Mumukit.runner_name = 'gobstones'
7
7
  Mumukit.configure do |config|
8
- config.docker_image = 'mumuki/mumuki-gobstones-worker:4.0'
8
+ config.docker_image = 'mumuki/mumuki-gobstones-worker:5.0'
9
9
  config.content_type = 'html'
10
10
  config.structured = true
11
11
  end
@@ -794,9 +794,10 @@
794
794
  this._setToolbox();
795
795
  },
796
796
  _setToolbox: function () {
797
+ const editor = $("mu-gobstones-custom-editor")[0];
798
+ const blockly = editor.getBlockly();
799
+ if(blockly.readOnly) return;
797
800
  $.get(this.toolboxUrl, function (toolboxXml) {
798
- const editor = $("mu-gobstones-custom-editor")[0];
799
- const blockly = editor.getBlockly();
800
801
  blockly.toolbox = { defaultToolbox: toolboxXml };
801
802
  editor.setTeacherActions(blockly);
802
803
  });
data/lib/version_hook.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module GobstonesVersionHook
2
- VERSION = '2.2.1'
2
+ VERSION = '2.3.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mumuki-gobstones-runner
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.1
4
+ version: 2.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rodrigo Alfonso
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-04-25 00:00:00.000000000 Z
11
+ date: 2019-05-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mumukit
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '2.26'
19
+ version: '2.33'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '2.26'
26
+ version: '2.33'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: sinatra-cross_origin
29
29
  requirement: !ruby/object:Gem::Requirement