atome 0.5.1.4 → 0.5.2.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (109) hide show
  1. checksums.yaml +4 -4
  2. data/Rakefile +23 -2
  3. data/lib/atome/atome.rb +40 -18
  4. data/lib/atome/extensions/atome.rb +5 -26
  5. data/lib/atome/extensions/geolocation.rb +0 -1
  6. data/lib/atome/extensions/matrix.rb +171 -0
  7. data/lib/atome/extensions/ping.rb +9 -11
  8. data/lib/atome/genesis/generators/atome.rb +14 -2
  9. data/lib/atome/genesis/generators/communication.rb +1 -1
  10. data/lib/atome/genesis/generators/event.rb +36 -0
  11. data/lib/atome/genesis/generators/identity.rb +28 -2
  12. data/lib/atome/genesis/generators/material.rb +21 -0
  13. data/lib/atome/genesis/generators/spatial.rb +1 -0
  14. data/lib/atome/genesis/generators/utility.rb +20 -2
  15. data/lib/atome/genesis/genesis.rb +2 -2
  16. data/lib/atome/genesis/sparkle.rb +1 -1
  17. data/lib/atome/helpers/callbacks.rb +76 -0
  18. data/lib/atome/helpers/essentials.rb +10 -5
  19. data/lib/atome/helpers/utilities.rb +52 -8
  20. data/lib/atome/kernel/universe.rb +0 -4
  21. data/lib/atome/presets/atome.rb +12 -8
  22. data/lib/atome/renderers/browser/atome.rb +8 -19
  23. data/lib/atome/renderers/browser/browser.rb +15 -210
  24. data/lib/atome/renderers/browser/effect.rb +2 -2
  25. data/lib/atome/renderers/browser/event.rb +49 -11
  26. data/lib/atome/renderers/browser/geometry.rb +2 -2
  27. data/lib/atome/renderers/browser/helpers/animation_helper.rb +69 -0
  28. data/lib/atome/renderers/browser/helpers/browser_helper.rb +17 -0
  29. data/lib/atome/renderers/browser/helpers/color_helper.rb +33 -0
  30. data/lib/atome/renderers/browser/helpers/drag_helper.rb +39 -0
  31. data/lib/atome/renderers/browser/helpers/effect_helper.rb +26 -0
  32. data/lib/atome/renderers/browser/helpers/event_helper.rb +59 -0
  33. data/lib/atome/renderers/browser/helpers/image_helper.rb +27 -0
  34. data/lib/atome/renderers/browser/helpers/shadow_helper.rb +33 -0
  35. data/lib/atome/renderers/browser/helpers/shape_helper.rb +22 -0
  36. data/lib/atome/renderers/browser/helpers/text_helper.rb +26 -0
  37. data/lib/atome/renderers/browser/helpers/video_helper.rb +43 -0
  38. data/lib/atome/renderers/browser/helpers/web_helper.rb +30 -0
  39. data/lib/atome/renderers/browser/identity.rb +10 -3
  40. data/lib/atome/renderers/browser/material.rb +28 -5
  41. data/lib/atome/renderers/browser/spatial.rb +36 -5
  42. data/lib/atome/renderers/browser/utility.rb +21 -12
  43. data/lib/atome/renderers/headless/utility.rb +2 -2
  44. data/lib/atome/renderers/html/atome.rb +5 -5
  45. data/lib/atome/renderers/html/effect.rb +1 -1
  46. data/lib/atome/renderers/html/event.rb +1 -1
  47. data/lib/atome/renderers/html/geometry.rb +2 -2
  48. data/lib/atome/renderers/html/html.rb +1 -1
  49. data/lib/atome/renderers/html/identity.rb +2 -2
  50. data/lib/atome/renderers/html/spatial.rb +5 -5
  51. data/lib/atome/renderers/html/utility.rb +7 -7
  52. data/lib/atome/renderers/server/utility.rb +2 -2
  53. data/lib/atome/version.rb +1 -1
  54. data/lib/atome.rb +6 -4
  55. data/sig/atome.rbs +1 -0
  56. data/sig/atome_js.rbs +1 -0
  57. data/vendor/assets/build/css/style.css +25 -17
  58. data/vendor/assets/build/index.html +12 -3
  59. data/vendor/assets/build/js/atome/atome.js +150 -145
  60. data/vendor/assets/build/js/atome/atome_helpers/atome_animate.js +65 -0
  61. data/vendor/assets/build/js/atome/atome_helpers/atome_drag.js +85 -0
  62. data/vendor/assets/build/js/atome/atome_helpers/atome_file.js +7 -0
  63. data/vendor/assets/build/js/atome/atome_helpers/atome_sort.js +20 -0
  64. data/vendor/assets/build/js/atome/atome_helpers/atome_time.js +10 -0
  65. data/vendor/assets/build/js/atome/atome_helpers/atome_video.js +12 -0
  66. data/vendor/assets/build/js/third_parties/popmotion.min.js +1 -1
  67. data/vendor/assets/build/js/third_parties/sortable.min.js +2 -0
  68. data/vendor/assets/build/js/third_parties/wad.min.js +9 -0
  69. data/vendor/assets/build/medias/audios/Binrpilot.mp3 +0 -0
  70. data/vendor/assets/build/medias/rubies/examples/_2_solve.rb +45 -0
  71. data/vendor/assets/build/medias/rubies/examples/_audio.rb +178 -0
  72. data/vendor/assets/build/medias/rubies/examples/_dataset.rb +82 -0
  73. data/vendor/assets/build/medias/rubies/examples/_markers.rb +57 -0
  74. data/vendor/assets/build/medias/rubies/examples/_os.rb +29 -0
  75. data/vendor/assets/build/medias/rubies/examples/_vie.rb +211 -0
  76. data/vendor/assets/build/medias/rubies/examples/animation.rb +81 -0
  77. data/vendor/assets/build/medias/rubies/examples/at.rb +21 -0
  78. data/vendor/assets/build/medias/rubies/examples/{atome.new.rb → atome_new.rb} +5 -5
  79. data/vendor/assets/build/medias/rubies/examples/bottom.rb +1 -1
  80. data/vendor/assets/build/medias/rubies/examples/center.rb +21 -0
  81. data/vendor/assets/build/medias/rubies/examples/clone.rb +20 -0
  82. data/vendor/assets/build/medias/rubies/examples/color.rb +20 -15
  83. data/vendor/assets/build/medias/rubies/examples/cursor.rb +7 -0
  84. data/vendor/assets/build/medias/rubies/examples/delete.rb +25 -3
  85. data/vendor/assets/build/medias/rubies/examples/drag.rb +39 -0
  86. data/vendor/assets/build/medias/rubies/examples/edit.rb +12 -0
  87. data/vendor/assets/build/medias/rubies/examples/empty_atome.rb +12 -0
  88. data/vendor/assets/build/medias/rubies/examples/hide.rb +7 -0
  89. data/vendor/assets/build/medias/rubies/examples/matrix.rb +58 -0
  90. data/vendor/assets/build/medias/rubies/examples/monitoring.rb +22 -11
  91. data/vendor/assets/build/medias/rubies/examples/mute.rb +22 -0
  92. data/vendor/assets/build/medias/rubies/examples/on.rb +7 -1
  93. data/vendor/assets/build/medias/rubies/examples/{parent.rb → parents.rb} +6 -6
  94. data/vendor/assets/build/medias/rubies/examples/pause.rb +15 -0
  95. data/vendor/assets/build/medias/rubies/examples/play.rb +15 -0
  96. data/vendor/assets/build/medias/rubies/examples/read.rb +7 -4
  97. data/vendor/assets/build/medias/rubies/examples/remove.rb +16 -0
  98. data/vendor/assets/build/medias/rubies/examples/right.rb +1 -1
  99. data/vendor/assets/build/medias/rubies/examples/schedule.rb +2 -2
  100. data/vendor/assets/build/medias/rubies/examples/shadow.rb +8 -1
  101. data/vendor/assets/build/medias/rubies/examples/sort.rb +19 -0
  102. data/vendor/assets/build/medias/rubies/examples/style.rb +4 -0
  103. data/vendor/assets/build/medias/rubies/examples/time.rb +14 -0
  104. data/vendor/assets/build/medias/rubies/examples/touch.rb +50 -7
  105. data/vendor/assets/build/medias/texts/lorem.txt +1 -0
  106. metadata +50 -7
  107. data/lib/atome/processors/utilities.rb +0 -10
  108. data/vendor/assets/build/medias/rubies/examples/_animation.rb +0 -0
  109. data/vendor/assets/build/medias/rubies/examples/_drag.rb +0 -44
@@ -0,0 +1,12 @@
1
+ # frozen_string_literal: true
2
+
3
+ t = text({ data: "hit the box to make me editable" })
4
+
5
+ b = box({ left: 333 })
6
+ b.touch(true) do
7
+ if t.edit.value == true
8
+ t.edit(false)
9
+ else
10
+ t.edit(true)
11
+ end
12
+ end
@@ -0,0 +1,12 @@
1
+ # frozen_string_literal: true
2
+
3
+ a= Atome.new()
4
+ t=template()
5
+ t2=template({})
6
+
7
+
8
+ puts "a : #{a}"
9
+
10
+ puts "t : #{t}"
11
+
12
+ puts "t2 : #{t2}"
@@ -0,0 +1,7 @@
1
+ # frozen_string_literal: true
2
+
3
+ bbb=box
4
+
5
+ wait 2 do
6
+ bbb.hide(true)
7
+ end
@@ -0,0 +1,58 @@
1
+ # frozen_string_literal: true
2
+
3
+ a = Matrix.new({ col: 1, row: 8, width: 120, height: 333, id: :vie_playground, name: :matrix_2, margin: 9,
4
+ matrix_style: { color: { red: 0.3, green: 0.3, blue: 0.6, alpha: 1 }, smooth: 20 },
5
+ cell_style: { color: { red: 0.333, green: 0.333, blue: 0.6, alpha: 1 }, smooth: 300, shadow: { blur: 6 }
6
+ #border: { color: :black, thickness: 0, pattern: :solid }
7
+ }
8
+ })
9
+
10
+ ######## tests
11
+
12
+ a.assign(2) do
13
+ curent_cell = self
14
+ curent_cell.image({ path: "./medias/images/moto.png", width: 33, height: 33})
15
+ curent_cell.active(:inactive)
16
+ touch(:long) do
17
+ if curent_cell.active.value ==:inactive
18
+ curent_cell.color(:yellow)
19
+ curent_cell.active(:active)
20
+ else
21
+ curent_cell.color(:red)
22
+ curent_cell.active(:inactive)
23
+ end
24
+ end
25
+ end
26
+
27
+ a.assign(3) do
28
+ color({ red: 0.6, green: 0.333, blue: 0.6, alpha: 1 })
29
+ grab(:vie_playground_3).shadow({ blur: 12 })
30
+ end
31
+
32
+
33
+ wait 2 do
34
+ a.add({ columns: 3 })
35
+ end
36
+
37
+ # add row
38
+ # wait 4 do
39
+ # a.add({ rows: 2 })
40
+ # end
41
+
42
+ # examples:
43
+
44
+ # add columns
45
+ # a.add({ columns: 3 })
46
+
47
+ # add row
48
+ # a.add({ rows: 2 })
49
+
50
+ # reformat
51
+ # a.reformat({rows: 4, cols: 2})
52
+
53
+ # resize matrix
54
+ # a.resize_matrix({ width: 666, height: 333 })
55
+
56
+ # crop matrix
57
+ # a.matrix.height(150)
58
+
@@ -1,17 +1,17 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- a = text({data: "open the console!"})
3
+ a = text({ data: "open the console!" })
4
4
  a.right(44).left(66)
5
5
 
6
- b = Atome.new(shape: { type: :shape, id: :my_shape, children: [],parents: [:view], renderers: [:browser],
6
+ b = Atome.new(shape: { type: :shape, id: :my_shape, children: [], parents: [:view], renderers: [:browser],
7
7
  left: 0, right: 33
8
8
  })
9
9
 
10
- c = Atome.new(shape: { type: :shape, id: :my_pix,children: [], parents: [:view], renderers: [:browser],
10
+ c = Atome.new(shape: { type: :shape, id: :my_pix, children: [], parents: [:view], renderers: [:browser],
11
11
  left: 50, right: 78
12
12
  })
13
13
 
14
- a.monitor({ atomes: grab(:view).children.value, particles: [:left] }) do |atome,element, value|
14
+ a.monitor({ atomes: grab(:view).children.value, particles: [:left] }) do |atome, element, value|
15
15
  puts "monitoring: #{atome.id}, #{element}, #{value}"
16
16
  end
17
17
 
@@ -19,15 +19,26 @@ b.left(936)
19
19
  b.left(777)
20
20
  c.left(888)
21
21
 
22
- #test 2
23
- a = text({data: 'touch me and open the console'})
22
+ # test 2
23
+ aa = text({ data: 'touch me and look in the console', top: 99, width: 399, left: 120 })
24
+ aa.touch(true) do
25
+ aa.color(:red)
26
+ aa.left(333)
27
+ aa.width(555)
28
+ aa.right(4)
29
+ aa.height(199)
30
+ end
31
+
32
+ aa.box({ id: :theboxy })
24
33
 
25
- a.touch(true) do
26
- a.color(:red)
27
- a.left(333)
34
+ aa.monitor({ atomes: grab(:view).children.value, particles: [:left] }) do |_atome, _element, value|
35
+ puts "the left value was change to : #{value}"
28
36
  end
29
37
 
30
- a.monitor({ atomes: grab(:view).children.value, particles: [:left] }) do |_atome,_element, value|
31
- puts "the left value was change to : #{value}"
38
+ aa.monitor({ atomes: grab(:view).children.value, particles: [:width] }) do |_atome, _element, value|
39
+ puts "the width's value was change to : #{value}"
40
+ end
32
41
 
42
+ aa.monitor({ atomes: grab(:view).children.value, particles: [:left], id: :my_monitorer }) do |_atome, _element, value|
43
+ puts "the second monitor left value was log to : #{value}"
33
44
  end
@@ -0,0 +1,22 @@
1
+ # frozen_string_literal: true
2
+
3
+ my_video2 = Atome.new(
4
+ video: { renderers: [:browser], id: :video9, type: :video, parents: [:view], path: './medias/videos/madmax.mp4',
5
+ left: 666, top: 333, width: 199, height: 99,
6
+ }) do |params|
7
+ puts "2- video callback time is #{params}, id is : #{id}"
8
+ end
9
+ my_video2.top(33)
10
+ my_video2.left(333)
11
+
12
+ my_video2.touch(true) do
13
+ my_video2.play(true) do |currentTime|
14
+ puts "2 - play callback time is : #{currentTime}, id is : #{id}"
15
+ end
16
+ wait 2 do
17
+ my_video2.mute(true)
18
+ wait 3 do
19
+ my_video2.mute
20
+ end
21
+ end
22
+ end
@@ -7,7 +7,9 @@ my_video = Atome.new(
7
7
  ) do |params|
8
8
  puts "video callback here #{params}"
9
9
  end
10
-
10
+ my_video.touch(true) do
11
+ my_video.pause(true)
12
+ end
11
13
  my_video.play(true)
12
14
 
13
15
  # video example
@@ -17,4 +19,8 @@ wait 4 do
17
19
  end
18
20
  grab(:video1).on(:pause) do |_event|
19
21
  puts :stopped
22
+ end
23
+
24
+ grab(:video1).on(:click) do |_event|
25
+ puts :touched
20
26
  end
@@ -1,15 +1,15 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  b=box({id: :c315})
4
- circle({id: :circle_12})
5
- grab(:c315).parents([:circle_12])
6
- b.parents([:circle_12])
4
+ circle({id: :circle_12, top: 0,drag: true})
7
5
 
6
+ b.parents([:circle_12])
8
7
 
9
- circle({ id: :circle_123, color: :cyan })
8
+ circle({ id: :circle_123, color: :cyan, left: 233, drag: true })
10
9
  box({ id: :box_1, left: 333 })
11
10
  bb=box({top: 99})
12
11
  grab(:box_1).parents([:circle_123])
13
12
  grab(:color_circle_123).parents([:box_1])
14
-
15
- bb.parents([:box_1])
13
+ #
14
+ bb.parents([:box_1])
15
+ grab(:c315).parents([:circle_12])
@@ -0,0 +1,15 @@
1
+ # frozen_string_literal: true
2
+
3
+ my_video = Atome.new(
4
+ video: { renderers: [:browser], id: :video1, type: :video, parents: [:view],
5
+ path: './medias/videos/avengers.mp4', left: 333, top: 33, width: 777
6
+ }
7
+ ) do |params|
8
+ puts "video callback here #{params}"
9
+ end
10
+
11
+ my_video.play(true)
12
+
13
+ my_video.touch(true) do
14
+ my_video.pause(true)
15
+ end
@@ -0,0 +1,15 @@
1
+ # frozen_string_literal: true
2
+
3
+ my_video = Atome.new(
4
+ video: { renderers: [:browser], id: :video1, type: :video, parents: [:view],clones: [],
5
+ time: 33, path: './medias/videos/avengers.mp4', left: 333, top: 33, width: 777
6
+ }
7
+ ) do |params|
8
+ puts "video callback here #{params}"
9
+ end
10
+
11
+ my_video.play(true)
12
+
13
+ my_video.touch(true) do
14
+ my_video.play(44)
15
+ end
@@ -1,7 +1,10 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  puts "Attention this method only work with a server due to security restriction "
4
- a = element
5
- a.read('rubies/examples/image.rb') do |params|
6
- text({data: params})
7
- end
4
+ a=box
5
+ a.touch(true) do
6
+ a.read('rubies/examples/image.rb') do |params|
7
+ text({data: params, visual:{size: 9}})
8
+ end
9
+ end
10
+
@@ -0,0 +1,16 @@
1
+ # frozen_string_literal: true
2
+
3
+ # TODO : some atomes and particles may need have extra code to be removed (eg: color)
4
+
5
+ b = box({ left: 666, smooth: 12, blur: 3, color: :red})
6
+
7
+ wait 1 do
8
+ b.remove(:blur)
9
+ b.remove(:left)
10
+ wait 1 do
11
+ b.remove(:color)
12
+ wait 1 do
13
+ b.remove(:smooth)
14
+ end
15
+ end
16
+ end
@@ -1,3 +1,3 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- box({right: 120 })
3
+ box({right: 120, left: :auto})
@@ -1,10 +1,10 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  _alarm_format = '2022,11,27,12,06,0'
4
- time_to_run = Time.now + 2
4
+ time_to_run = Time.now + 3
5
5
  puts 'event schedule'
6
6
  a = element
7
7
 
8
8
  a.schedule(time_to_run) do
9
- alert 'event executed'
9
+ puts 'event executed'
10
10
  end
@@ -2,6 +2,9 @@
2
2
 
3
3
  b = box({ id: :the_box, left: 99, top: 99 })
4
4
 
5
+
6
+
7
+
5
8
  s = b.shadow({ renderers: [:browser], id: :shadow2, type: :shadow, parents: [], children: [],
6
9
  left: 3, top: 9, blur: 3, direction: :inset,
7
10
  red: 0, green: 0, blue: 0, alpha: 1
@@ -9,7 +12,7 @@ s = b.shadow({ renderers: [:browser], id: :shadow2, type: :shadow, parents: [],
9
12
 
10
13
 
11
14
  wait 1 do
12
- s.parents([:the_box])
15
+ s.attach([:the_box])
13
16
  # or
14
17
  # b.children([:shadow2])
15
18
  wait 1 do
@@ -27,4 +30,8 @@ wait 1 do
27
30
  s.green(0.7)
28
31
  end
29
32
  end
33
+ end
34
+
35
+ wait 3 do
36
+ b.shadow({ blur: 33 })
30
37
  end
@@ -0,0 +1,19 @@
1
+ # frozen_string_literal: true
2
+
3
+ a = box({ width: 333, height: 333, id: :the_grid })
4
+ i = 0
5
+ while i < 16
6
+ b = Atome.new(
7
+ shape: { renderers: [:browser],id: "the_shape#{i}", type: :shape, parents: [:the_grid], children: [],
8
+ width: 50, height: 50,
9
+ color: { renderers: [:browser], id: :c31, type: :color, parents: ["the_shape#{i}"], children: [],
10
+ red: 1, green: 0.15, blue: 0.15, alpha: 0.6 } }
11
+ )
12
+ b.text({ data: "item#{i + 1}", visual: { size: 12 } })
13
+ i += 1
14
+ end
15
+
16
+ a.sort(true) do |el|
17
+ puts "just sorted : #{el}"
18
+ end
19
+
@@ -0,0 +1,4 @@
1
+ # frozen_string_literal: true
2
+
3
+ b=box
4
+ b.style({color: :red, left: 33, top: 333, width: 333})
@@ -0,0 +1,14 @@
1
+ # frozen_string_literal: true
2
+
3
+ my_video = Atome.new(
4
+ video: { renderers: [:browser], id: :video1, type: :video, parents: [:view],
5
+ time: 33, path: './medias/videos/avengers.mp4', left: 333, top: 33, width: 777
6
+ }
7
+ ) do |params|
8
+ puts "video callback here #{params}"
9
+ end
10
+ my_video.touch(true) do
11
+ grab(:video1).time(5)
12
+ my_video.pause(true)
13
+ end
14
+ my_video.play(true)
@@ -1,13 +1,56 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- b = box({ width: 333, left: 666})
3
+ separator=120
4
+ b=box({ left: separator, id: :test_box })
5
+ c=box({ left: b.left.value+separator })
6
+ d=box({ left: c.left.value+separator })
7
+ e=box({ left: d.left.value+separator })
4
8
 
5
- b.touch(true) do
6
- color({ render: [:html], id: "color_#{Universe.atomes.length}", type: :color,
7
- red: 1, green: 0.33, blue: 0.22, alpha: 1 })
9
+ b.touch(:down) do
10
+ b.color(:red)
11
+ c.color(:red)
12
+ d.color(:red)
13
+ e.color(:red)
8
14
  end
15
+ b.text({data: :down})
9
16
 
10
- text.touch(true) do
11
- color(:yellow)
12
- box
17
+ c.touch(:long) do
18
+ b.color(:blue)
19
+ c.color(:blue)
20
+ d.color(:blue)
21
+ e.color(:blue)
22
+ end
23
+ c.text({data: :long})
24
+
25
+ d.touch(:up) do
26
+ b.color(:yellow)
27
+ c.color(:yellow)
28
+ d.color(:yellow)
29
+ e.color(:yellow)
30
+ end
31
+ d.text({data: :up})
32
+ e.touch(:double) do
33
+ b.color(:black)
34
+ c.color(:black)
35
+ d.color(:black)
36
+ e.color(:black)
37
+ end
38
+ e.text({data: :double})
39
+
40
+ ccc=circle
41
+ ccc.top(199)
42
+
43
+ # def unbind(val=nil)
44
+ # id_found=self.atome[:id]
45
+ # `
46
+ # const el = document.getElementById(#{id_found});
47
+ # interact('#'+#{id_found}).unset(#{val});
48
+ # `
49
+ # end
50
+ b.touch(:long) do
51
+ b.color(:cyan)
52
+ end
53
+
54
+ ccc.touch(true) do
55
+ b.unbind(:tap)
13
56
  end
@@ -0,0 +1 @@
1
+ lorem ipsum...
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: atome
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1.4
4
+ version: 0.5.2.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jean-Eric Godard
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-11-27 00:00:00.000000000 Z
11
+ date: 2022-12-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: arduino_firmata
@@ -380,6 +380,7 @@ files:
380
380
  - lib/atome/atome.rb
381
381
  - lib/atome/extensions/atome.rb
382
382
  - lib/atome/extensions/geolocation.rb
383
+ - lib/atome/extensions/matrix.rb
383
384
  - lib/atome/extensions/ping.rb
384
385
  - lib/atome/extensions/sha.rb
385
386
  - lib/atome/genesis/generators/atome.rb
@@ -414,12 +415,23 @@ files:
414
415
  - lib/atome/kernel/essentials.rb
415
416
  - lib/atome/kernel/universe.rb
416
417
  - lib/atome/presets/atome.rb
417
- - lib/atome/processors/utilities.rb
418
418
  - lib/atome/renderers/browser/atome.rb
419
419
  - lib/atome/renderers/browser/browser.rb
420
420
  - lib/atome/renderers/browser/effect.rb
421
421
  - lib/atome/renderers/browser/event.rb
422
422
  - lib/atome/renderers/browser/geometry.rb
423
+ - lib/atome/renderers/browser/helpers/animation_helper.rb
424
+ - lib/atome/renderers/browser/helpers/browser_helper.rb
425
+ - lib/atome/renderers/browser/helpers/color_helper.rb
426
+ - lib/atome/renderers/browser/helpers/drag_helper.rb
427
+ - lib/atome/renderers/browser/helpers/effect_helper.rb
428
+ - lib/atome/renderers/browser/helpers/event_helper.rb
429
+ - lib/atome/renderers/browser/helpers/image_helper.rb
430
+ - lib/atome/renderers/browser/helpers/shadow_helper.rb
431
+ - lib/atome/renderers/browser/helpers/shape_helper.rb
432
+ - lib/atome/renderers/browser/helpers/text_helper.rb
433
+ - lib/atome/renderers/browser/helpers/video_helper.rb
434
+ - lib/atome/renderers/browser/helpers/web_helper.rb
423
435
  - lib/atome/renderers/browser/identity.rb
424
436
  - lib/atome/renderers/browser/material.rb
425
437
  - lib/atome/renderers/browser/opal_browser.rb
@@ -449,6 +461,7 @@ files:
449
461
  - lib/atome/renderers/server/utility.rb
450
462
  - lib/atome/version.rb
451
463
  - sig/atome.rbs
464
+ - sig/atome_js.rbs
452
465
  - vendor/assets/Guardfile
453
466
  - vendor/assets/Rakefile
454
467
  - vendor/assets/application/index.rb
@@ -458,15 +471,24 @@ files:
458
471
  - vendor/assets/build/favicon.ico
459
472
  - vendor/assets/build/index.html
460
473
  - vendor/assets/build/js/atome/atome.js
474
+ - vendor/assets/build/js/atome/atome_helpers/atome_animate.js
475
+ - vendor/assets/build/js/atome/atome_helpers/atome_drag.js
476
+ - vendor/assets/build/js/atome/atome_helpers/atome_file.js
477
+ - vendor/assets/build/js/atome/atome_helpers/atome_sort.js
478
+ - vendor/assets/build/js/atome/atome_helpers/atome_time.js
479
+ - vendor/assets/build/js/atome/atome_helpers/atome_video.js
461
480
  - vendor/assets/build/js/third_parties/fabric.min.js
462
481
  - vendor/assets/build/js/third_parties/interact.min.js
463
482
  - vendor/assets/build/js/third_parties/interact.min.js.map
464
483
  - vendor/assets/build/js/third_parties/ping.min.js
465
484
  - vendor/assets/build/js/third_parties/popmotion.min.js
466
485
  - vendor/assets/build/js/third_parties/sha256.min.js
486
+ - vendor/assets/build/js/third_parties/sortable.min.js
467
487
  - vendor/assets/build/js/third_parties/three.min.js
468
488
  - vendor/assets/build/js/third_parties/w3color.js
489
+ - vendor/assets/build/js/third_parties/wad.min.js
469
490
  - vendor/assets/build/js/third_parties/zim.min.js
491
+ - vendor/assets/build/medias/audios/Binrpilot.mp3
470
492
  - vendor/assets/build/medias/audios/audio_missing.wav
471
493
  - vendor/assets/build/medias/audios/clap.wav
472
494
  - vendor/assets/build/medias/audios/cowbell.wav
@@ -579,41 +601,61 @@ files:
579
601
  - vendor/assets/build/medias/javascripts/test.js
580
602
  - vendor/assets/build/medias/rubies/examples/!run.rb
581
603
  - vendor/assets/build/medias/rubies/examples/_2_solve.rb
582
- - vendor/assets/build/medias/rubies/examples/_animation.rb
583
- - vendor/assets/build/medias/rubies/examples/_drag.rb
584
- - vendor/assets/build/medias/rubies/examples/atome.new.rb
604
+ - vendor/assets/build/medias/rubies/examples/_audio.rb
605
+ - vendor/assets/build/medias/rubies/examples/_dataset.rb
606
+ - vendor/assets/build/medias/rubies/examples/_markers.rb
607
+ - vendor/assets/build/medias/rubies/examples/_os.rb
608
+ - vendor/assets/build/medias/rubies/examples/_vie.rb
609
+ - vendor/assets/build/medias/rubies/examples/animation.rb
610
+ - vendor/assets/build/medias/rubies/examples/at.rb
611
+ - vendor/assets/build/medias/rubies/examples/atome_new.rb
585
612
  - vendor/assets/build/medias/rubies/examples/auto_height.rb
586
613
  - vendor/assets/build/medias/rubies/examples/auto_width.rb
587
614
  - vendor/assets/build/medias/rubies/examples/blur.rb
588
615
  - vendor/assets/build/medias/rubies/examples/bottom.rb
589
616
  - vendor/assets/build/medias/rubies/examples/box.rb
617
+ - vendor/assets/build/medias/rubies/examples/center.rb
590
618
  - vendor/assets/build/medias/rubies/examples/circle.rb
591
619
  - vendor/assets/build/medias/rubies/examples/clear.rb
620
+ - vendor/assets/build/medias/rubies/examples/clone.rb
592
621
  - vendor/assets/build/medias/rubies/examples/code.rb
593
622
  - vendor/assets/build/medias/rubies/examples/color.rb
594
623
  - vendor/assets/build/medias/rubies/examples/create_atome_in_atome.rb
624
+ - vendor/assets/build/medias/rubies/examples/cursor.rb
595
625
  - vendor/assets/build/medias/rubies/examples/delete.rb
626
+ - vendor/assets/build/medias/rubies/examples/drag.rb
627
+ - vendor/assets/build/medias/rubies/examples/edit.rb
596
628
  - vendor/assets/build/medias/rubies/examples/element.rb
629
+ - vendor/assets/build/medias/rubies/examples/empty_atome.rb
597
630
  - vendor/assets/build/medias/rubies/examples/fullscreen.rb
598
631
  - vendor/assets/build/medias/rubies/examples/get_renderer_list.rb
599
632
  - vendor/assets/build/medias/rubies/examples/grab.rb
600
633
  - vendor/assets/build/medias/rubies/examples/height.rb
634
+ - vendor/assets/build/medias/rubies/examples/hide.rb
601
635
  - vendor/assets/build/medias/rubies/examples/id.rb
602
636
  - vendor/assets/build/medias/rubies/examples/image.rb
603
637
  - vendor/assets/build/medias/rubies/examples/left.rb
604
638
  - vendor/assets/build/medias/rubies/examples/link.rb
639
+ - vendor/assets/build/medias/rubies/examples/matrix.rb
605
640
  - vendor/assets/build/medias/rubies/examples/monitoring.rb
641
+ - vendor/assets/build/medias/rubies/examples/mute.rb
606
642
  - vendor/assets/build/medias/rubies/examples/on.rb
607
- - vendor/assets/build/medias/rubies/examples/parent.rb
643
+ - vendor/assets/build/medias/rubies/examples/parents.rb
644
+ - vendor/assets/build/medias/rubies/examples/pause.rb
645
+ - vendor/assets/build/medias/rubies/examples/play.rb
608
646
  - vendor/assets/build/medias/rubies/examples/read.rb
609
647
  - vendor/assets/build/medias/rubies/examples/refresh.rb
648
+ - vendor/assets/build/medias/rubies/examples/remove.rb
610
649
  - vendor/assets/build/medias/rubies/examples/repeat.rb
611
650
  - vendor/assets/build/medias/rubies/examples/right.rb
612
651
  - vendor/assets/build/medias/rubies/examples/rotate.rb
613
652
  - vendor/assets/build/medias/rubies/examples/schedule.rb
614
653
  - vendor/assets/build/medias/rubies/examples/shadow.rb
615
654
  - vendor/assets/build/medias/rubies/examples/smooth.rb
655
+ - vendor/assets/build/medias/rubies/examples/sort.rb
656
+ - vendor/assets/build/medias/rubies/examples/style.rb
616
657
  - vendor/assets/build/medias/rubies/examples/text.rb
658
+ - vendor/assets/build/medias/rubies/examples/time.rb
617
659
  - vendor/assets/build/medias/rubies/examples/top.rb
618
660
  - vendor/assets/build/medias/rubies/examples/touch.rb
619
661
  - vendor/assets/build/medias/rubies/examples/video.rb
@@ -623,6 +665,7 @@ files:
623
665
  - vendor/assets/build/medias/rubies/test.rb
624
666
  - vendor/assets/build/medias/rubies/text_read.rb
625
667
  - vendor/assets/build/medias/rubies/users/code.rb
668
+ - vendor/assets/build/medias/texts/lorem.txt
626
669
  - vendor/assets/build/medias/utils/infos/color.rb
627
670
  - vendor/assets/build/medias/utils/infos/width.rb
628
671
  - vendor/assets/build/medias/videos/avengers.mp4
@@ -1,10 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- # Atome processors
4
- class Atome
5
- private
6
-
7
- def data_code_processor(data)
8
- eval data
9
- end
10
- end
@@ -1,44 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- box({width: 333, height: 333, id: :the_constraint_box, color: :orange})
4
-
5
- b = box
6
-
7
- b.drag({ remove: true}) do |position|
8
- # below here is the callback :
9
- puts "1 - callback drag position: #{position}"
10
- puts "1 - callback id is: #{id}"
11
- end
12
-
13
- wait 4 do
14
- b.drag({ max: { left: 333 ,right: 90, top: 333, bottom: 30}})
15
- end
16
-
17
- bb = box({ left: 120, color: :green })
18
- bb.touch(true) do
19
- alert left
20
- end
21
-
22
- bb.drag({ lock: :x }) do |position|
23
- # below here is the callback :
24
- puts "2 - drag position: #{position}"
25
- puts "2 - id is: #{id}"
26
- end
27
- #TODO: when we add a color we must change the code : do we create a new color with it's id or do we replace the old one?
28
- #
29
- bbb = box({ left: 120, top: 120 })
30
- bbb.drag({}) do |position|
31
- # below here is the callback :
32
- puts "bbb drag position: #{position}"
33
- puts "bbb id is: #{id}"
34
- end
35
- bbb.color(:black)
36
-
37
- bbb.remove(:drag)
38
- wait 3 do
39
- bbb.drag({fixed: true}) do |position|
40
- puts position
41
- end
42
- end
43
-
44
- circle({drag: {inside: :the_constraint_box}, color: :red})