atome 0.5.4.1.7 → 0.5.5.6.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -1
- data/Gemfile +3 -1
- data/README.md +70 -1
- data/Rakefile +246 -75
- data/app_builder_helpers/Rakefile +276 -288
- data/documentation/basic.md +242 -0
- data/documentation/deep learning/architecture.txt +3763 -0
- data/documentation/deep learning/atome.png +0 -0
- data/documentation/deep learning/basic_infos.txt +227 -0
- data/documentation/deep learning/example_of_users_code.rb +1810 -0
- data/documentation/deep learning/misc.txt +24 -0
- data/documentation/deep learning/ruby_js_example.rb +272 -0
- data/documentation/deep learning/wasm_script_help.text +14 -0
- data/documentation/framework/enhance_atome.md +1 -1
- data/documentation/tutorials/tutorials.md +7 -0
- data/exe/atome +308 -208
- data/lib/atome/atome.rb +52 -156
- data/lib/atome/extensions/atome.rb +129 -47
- data/lib/atome/extensions/mathematics.rb +20 -0
- data/lib/atome/extensions/ping.rb +2 -3
- data/lib/atome/genesis/generators/atome.rb +57 -30
- data/lib/atome/genesis/generators/communication.rb +9 -0
- data/lib/atome/genesis/generators/effect.rb +0 -1
- data/lib/atome/genesis/generators/event.rb +279 -43
- data/lib/atome/genesis/generators/geometry.rb +1 -10
- data/lib/atome/genesis/generators/hierarchy.rb +103 -0
- data/lib/atome/genesis/generators/identity.rb +45 -84
- data/lib/atome/genesis/generators/material.rb +31 -34
- data/lib/atome/genesis/generators/property.rb +31 -0
- data/lib/atome/genesis/generators/security.rb +31 -0
- data/lib/atome/genesis/generators/spatial.rb +3 -5
- data/lib/atome/genesis/generators/time.rb +0 -1
- data/lib/atome/genesis/generators/utility.rb +181 -66
- data/lib/atome/genesis/genesis.rb +152 -55
- data/lib/atome/genesis/sparkle.rb +59 -75
- data/lib/atome/helpers/color_helper/color/rgb/colors.rb +1 -1
- data/lib/atome/helpers/color_helper/color/rgb.rb +1 -1
- data/lib/atome/helpers/color_helper/color.rb +226 -7
- data/lib/atome/helpers/essentials.rb +22 -26
- data/lib/atome/helpers/security.rb +71 -0
- data/lib/atome/helpers/utilities.rb +191 -178
- data/lib/atome/kernel/black_matter.rb +22 -0
- data/lib/atome/kernel/universe.rb +123 -24
- data/lib/atome/presets/atome.rb +39 -35
- data/lib/atome/version.rb +3 -2
- data/lib/atome.rb +12 -12
- data/lib/atome_relative.rb +36 -0
- data/lib/{atome/renderers → platform_specific}/opal/atome_opal_extensions.rb +4 -1
- data/lib/{atome/renderers → platform_specific}/opal/extensions/color.rb +12 -5
- data/lib/{atome/renderers → platform_specific}/opal/extensions/geolocation.rb +1 -0
- data/lib/platform_specific/opal/extensions/js.rb +21 -0
- data/lib/platform_specific/opal/extensions/object.rb +6 -0
- data/lib/platform_specific/opal/extensions/ping.rb +31 -0
- data/lib/{atome/renderers → platform_specific}/opal/extensions/sha.rb +4 -2
- data/lib/platform_specific/wasm/atome_wasm_extensions.rb +11 -0
- data/lib/renderers/headless/headless.rb +18 -0
- data/lib/renderers/headless/index.rb +6 -0
- data/lib/renderers/headless/index_relative.rb +6 -0
- data/lib/renderers/headless/utility.rb +6 -0
- data/{vendor/assets/src/medias/rubies/examples/top.rb → lib/renderers/html/atome.rb} +0 -1
- data/lib/renderers/html/atome_html.rb +22 -0
- data/lib/renderers/html/effect.rb +26 -0
- data/lib/renderers/html/event.rb +43 -0
- data/lib/renderers/html/geometry.rb +31 -0
- data/lib/renderers/html/hierarchy.rb +233 -0
- data/lib/renderers/html/html.rb +1112 -0
- data/lib/renderers/html/identity.rb +84 -0
- data/lib/renderers/html/index.rb +19 -0
- data/lib/renderers/html/index_relative.rb +20 -0
- data/lib/renderers/html/material.rb +53 -0
- data/lib/renderers/html/property.rb +24 -0
- data/lib/renderers/html/spatial.rb +46 -0
- data/lib/renderers/html/time.rb +1 -0
- data/lib/renderers/html/utility.rb +38 -0
- data/lib/renderers/renderer.rb +16 -0
- data/lib/renderers/server/index.rb +4 -0
- data/lib/renderers/server/index_relative.rb +4 -0
- data/lib/renderers/server/utility.rb +4 -0
- data/sig/atome.rbs +6 -0
- data/sig/object.rbs +4 -0
- data/sig/universe.rbs +3 -0
- data/vendor/assets/Rakefile +3 -3
- data/vendor/assets/application/examples/a_concat.rb +16 -0
- data/vendor/assets/application/examples/affect.rb +8 -0
- data/vendor/assets/application/examples/animation.rb +96 -0
- data/vendor/assets/application/examples/apply.rb +8 -0
- data/vendor/assets/application/examples/atome.rb +5 -0
- data/vendor/assets/application/examples/attach.rb +34 -0
- data/vendor/assets/application/examples/attached.rb +38 -0
- data/vendor/assets/application/examples/basic_understanding.rb +52 -0
- data/vendor/assets/application/examples/browse.rb +17 -0
- data/vendor/assets/application/examples/callback.rb +20 -0
- data/vendor/assets/application/examples/category.rb +12 -0
- data/vendor/assets/application/examples/clear.rb +96 -0
- data/vendor/assets/application/examples/clones.rb +177 -0
- data/vendor/assets/application/examples/code.rb +13 -0
- data/vendor/assets/application/examples/color.rb +54 -0
- data/vendor/assets/application/examples/convert.rb +163 -0
- data/vendor/assets/application/examples/copy.rb +25 -0
- data/vendor/assets/application/examples/copybck.rb +68 -0
- data/vendor/assets/application/examples/debug.rb +78 -0
- data/vendor/assets/application/examples/delete.rb +93 -0
- data/vendor/assets/application/examples/display.rb +279 -0
- data/vendor/assets/application/examples/display_bck.rb +164 -0
- data/vendor/assets/application/examples/drag.rb +45 -0
- data/vendor/assets/application/examples/drop.rb +35 -0
- data/vendor/assets/application/examples/duplicate.rb +64 -0
- data/vendor/assets/application/examples/edit.rb +21 -0
- data/vendor/assets/application/examples/encode.rb +6 -0
- data/vendor/assets/application/examples/file.rb +50 -0
- data/vendor/assets/application/examples/find.rb +157 -0
- data/vendor/assets/application/examples/generator_and_build.rb +15 -0
- data/vendor/assets/application/examples/getter.rb +16 -0
- data/vendor/assets/application/examples/grab.rb +14 -0
- data/vendor/assets/application/examples/gradient.rb +35 -0
- data/vendor/assets/application/examples/group.rb +44 -0
- data/vendor/assets/application/examples/hierarchy.rb +21 -0
- data/vendor/assets/application/examples/history.rb +31 -0
- data/vendor/assets/application/examples/hypertext.rb +113 -0
- data/vendor/assets/application/examples/image.rb +5 -0
- data/vendor/assets/application/examples/keyboard.rb +59 -0
- data/vendor/assets/application/examples/layout.rb +227 -0
- data/vendor/assets/application/examples/login.rb +10 -0
- data/vendor/assets/application/examples/markup.rb +4 -0
- data/vendor/assets/application/examples/match.rb +115 -0
- data/vendor/assets/application/examples/messaging.rb +16 -0
- data/vendor/assets/application/examples/monitor.rb +14 -0
- data/vendor/assets/application/examples/on_resize.rb +7 -0
- data/vendor/assets/{src/medias/rubies/examples/get_renderer_list.rb → application/examples/online.rb} +1 -1
- data/vendor/assets/application/examples/over.rb +29 -0
- data/vendor/assets/application/examples/paint.rb +23 -0
- data/vendor/assets/application/examples/particles.rb +4 -0
- data/vendor/assets/application/examples/percent_to_px.rb +4 -0
- data/vendor/assets/application/examples/play.rb +50 -0
- data/vendor/assets/application/examples/presets.rb +33 -0
- data/vendor/assets/application/examples/random.rb +42 -0
- data/vendor/assets/application/examples/raw_html.rb +48 -0
- data/vendor/assets/application/examples/read.rb +11 -0
- data/vendor/assets/application/examples/refresh.rb +62 -0
- data/vendor/assets/application/examples/remove.rb +47 -0
- data/vendor/assets/application/examples/repeat.rb +26 -0
- data/vendor/assets/application/examples/resize.rb +17 -0
- data/vendor/assets/application/examples/scroll.rb +11 -0
- data/vendor/assets/application/examples/security.rb +76 -0
- data/vendor/assets/application/examples/selected.rb +30 -0
- data/vendor/assets/application/examples/shadow.rb +46 -0
- data/vendor/assets/application/examples/shapes.rb +6 -0
- data/vendor/assets/{src/medias/rubies → application}/examples/smooth.rb +5 -1
- data/vendor/assets/application/examples/style.rb +4 -0
- data/vendor/assets/application/examples/sync.rb +39 -0
- data/vendor/assets/application/examples/tagged.rb +24 -0
- data/vendor/assets/application/examples/terminal.rb +4 -0
- data/vendor/assets/application/examples/text.rb +5 -0
- data/vendor/assets/application/examples/touch.rb +38 -0
- data/vendor/assets/application/examples/type_mutation.rb +18 -0
- data/vendor/assets/application/examples/universe.rb +8 -0
- data/vendor/assets/application/examples/vector.rb +24 -0
- data/vendor/assets/application/examples/video.rb +14 -0
- data/vendor/assets/application/examples/wait.rb +6 -0
- data/vendor/assets/application/examples/www.rb +10 -0
- data/vendor/assets/application/index.rb +1 -1
- data/vendor/assets/application/test.rb +29 -0
- data/vendor/assets/application/works/photos.rb +672 -0
- data/vendor/assets/application/works/photos2.rb +218 -0
- data/vendor/assets/application/works/photos3.rb +343 -0
- data/vendor/assets/application/works/photos4.rb +34 -0
- data/vendor/assets/application/works/photos6.rb +6 -0
- data/vendor/assets/application/works/trigga.rb +0 -0
- data/vendor/assets/application/works/vie.rb +74 -0
- data/vendor/assets/server/atome_server.rb +37 -41
- data/vendor/assets/server/atome_server_wasm.rb +112 -0
- data/vendor/assets/server/capture.rb +10 -0
- data/vendor/assets/server/config.ru +5 -4
- data/vendor/assets/src/css/style.css +29 -4
- data/vendor/assets/src/index.html +31 -38
- data/vendor/assets/src/index_opal.html +42 -0
- data/vendor/assets/src/index_server.html +43 -0
- data/vendor/assets/src/index_server_wasm.html +46 -0
- data/vendor/assets/src/js/atome/atome.js +170 -150
- data/vendor/assets/src/js/atome/atome_helpers/add_font.js +46 -0
- data/vendor/assets/src/js/atome/atome_helpers/atome_drag.js +3 -1
- data/vendor/assets/src/js/atome/atome_helpers/atome_events.js +12 -7
- data/vendor/assets/src/js/atome/atome_helpers/communication.js +126 -0
- data/vendor/assets/src/js/atome/atome_helpers/{atome_file.js → file.js} +1 -1
- data/vendor/assets/src/js/atome/specific/opal.js +3 -0
- data/vendor/assets/src/js/atome/specific/wasm.js +12 -0
- data/vendor/assets/src/js/third_parties/browser.script.iife.min.js +13 -0
- data/vendor/assets/src/js/third_parties/fabric.min.js +1 -1
- data/vendor/assets/src/js/third_parties/html-to-image.min.js +2 -0
- data/vendor/assets/src/js/third_parties/jsencrypt.min.js +2 -0
- data/vendor/assets/src/js/third_parties/papaparse.min.js +7 -0
- data/vendor/assets/src/medias/fonts/Roboto/LICENSE.txt +202 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-Black.ttf +0 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-BlackItalic.ttf +0 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-Bold.ttf +0 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-BoldItalic.ttf +0 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-Italic.ttf +0 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-Light.ttf +0 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-LightItalic.ttf +0 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-Medium.ttf +0 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-MediumItalic.ttf +0 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-Regular.ttf +0 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-Thin.ttf +0 -0
- data/vendor/assets/src/medias/fonts/Roboto/Roboto-ThinItalic.ttf +0 -0
- data/vendor/assets/src/medias/images/logos/Facebook.svg +1 -1
- data/vendor/assets/src/medias/images/logos/LinkedIn-full.svg +109 -0
- data/vendor/assets/src/medias/images/logos/LinkedIn.svg +11 -0
- data/vendor/assets/src/medias/images/logos/X.svg +5 -0
- data/vendor/assets/src-tauri/Cargo.toml +1 -1
- data/vendor/assets/src-tauri/src/main.rs +59 -5
- data/vendor/assets/src-tauri/tauri.conf.json +1 -1
- data/vendor/assets/src-wasm/wasm/wasi-vfs-osx_arm +0 -0
- data/vendor/assets/src-wasm/wasm/wasi-vfs-osx_x86 +0 -0
- data/vendor/assets/src-wasm/wasm/wasi-vfs-unix +0 -0
- data/vendor/assets/src-wasm/wasm/wasi-vfs.exe +0 -0
- metadata +188 -180
- data/lib/atome/extensions/mathematic.rb +0 -20
- data/lib/atome/extensions/matrix.rb +0 -346
- data/lib/atome/helpers/callbacks.rb +0 -133
- data/lib/atome/kernel/batch.rb +0 -26
- data/lib/atome/kernel/essentials.rb +0 -23
- data/lib/atome/renderers/browser/atome.rb +0 -158
- data/lib/atome/renderers/browser/browser.rb +0 -47
- data/lib/atome/renderers/browser/effect.rb +0 -23
- data/lib/atome/renderers/browser/event.rb +0 -96
- data/lib/atome/renderers/browser/geometry.rb +0 -27
- data/lib/atome/renderers/browser/helpers/animation_helper.rb +0 -69
- data/lib/atome/renderers/browser/helpers/browser_helper.rb +0 -101
- data/lib/atome/renderers/browser/helpers/color_helper.rb +0 -80
- data/lib/atome/renderers/browser/helpers/drag_helper.rb +0 -52
- data/lib/atome/renderers/browser/helpers/drop_helper.rb +0 -13
- data/lib/atome/renderers/browser/helpers/effect_helper.rb +0 -23
- data/lib/atome/renderers/browser/helpers/event_helper.rb +0 -76
- data/lib/atome/renderers/browser/helpers/image_helper.rb +0 -27
- data/lib/atome/renderers/browser/helpers/over_helper.rb +0 -13
- data/lib/atome/renderers/browser/helpers/shadow_helper.rb +0 -74
- data/lib/atome/renderers/browser/helpers/shape_helper.rb +0 -22
- data/lib/atome/renderers/browser/helpers/text_helper.rb +0 -38
- data/lib/atome/renderers/browser/helpers/video_helper.rb +0 -50
- data/lib/atome/renderers/browser/helpers/web_helper.rb +0 -26
- data/lib/atome/renderers/browser/identity.rb +0 -61
- data/lib/atome/renderers/browser/material.rb +0 -121
- data/lib/atome/renderers/browser/opal_add_on.rb +0 -31
- data/lib/atome/renderers/browser/opal_browser.rb +0 -6
- data/lib/atome/renderers/browser/spatial.rb +0 -59
- data/lib/atome/renderers/browser/time.rb +0 -3
- data/lib/atome/renderers/browser/utility.rb +0 -49
- data/lib/atome/renderers/headless/headless.rb +0 -10
- data/lib/atome/renderers/headless/utility.rb +0 -6
- data/lib/atome/renderers/html/atome.rb +0 -49
- data/lib/atome/renderers/html/effect.rb +0 -19
- data/lib/atome/renderers/html/event.rb +0 -9
- data/lib/atome/renderers/html/geometry.rb +0 -11
- data/lib/atome/renderers/html/html.rb +0 -42
- data/lib/atome/renderers/html/identity.rb +0 -14
- data/lib/atome/renderers/html/opal_browser.rb +0 -6
- data/lib/atome/renderers/html/spatial.rb +0 -28
- data/lib/atome/renderers/html/utility.rb +0 -17
- data/lib/atome/renderers/opal/extensions/atome.rb +0 -29
- data/lib/atome/renderers/opal/extensions/ping.rb +0 -18
- data/lib/atome/renderers/renderer.rb +0 -15
- data/lib/atome/renderers/server/server.rb +0 -10
- data/lib/atome/renderers/server/utility.rb +0 -6
- data/vendor/assets/aui.rb +0 -5
- data/vendor/assets/r&d/misc.rb +0 -219
- data/vendor/assets/r&d/ping.rb +0 -3
- data/vendor/assets/r&d/storage.rb +0 -9
- data/vendor/assets/r&d/view_example.rb +0 -21
- data/vendor/assets/src/js/atome/atome_helpers/atome_communication.js +0 -40
- data/vendor/assets/src/medias/javascripts/test.js +0 -1
- data/vendor/assets/src/medias/rubies/demos.rb +0 -63
- data/vendor/assets/src/medias/rubies/examples/add.rb +0 -24
- data/vendor/assets/src/medias/rubies/examples/animation.rb +0 -81
- data/vendor/assets/src/medias/rubies/examples/atome_new.rb +0 -27
- data/vendor/assets/src/medias/rubies/examples/attach.rb +0 -15
- data/vendor/assets/src/medias/rubies/examples/attached.rb +0 -15
- data/vendor/assets/src/medias/rubies/examples/auto_height.rb +0 -5
- data/vendor/assets/src/medias/rubies/examples/auto_width.rb +0 -4
- data/vendor/assets/src/medias/rubies/examples/batch.rb +0 -17
- data/vendor/assets/src/medias/rubies/examples/blur.rb +0 -4
- data/vendor/assets/src/medias/rubies/examples/bottom.rb +0 -3
- data/vendor/assets/src/medias/rubies/examples/box.rb +0 -20
- data/vendor/assets/src/medias/rubies/examples/center.rb +0 -21
- data/vendor/assets/src/medias/rubies/examples/circle.rb +0 -3
- data/vendor/assets/src/medias/rubies/examples/class.rb +0 -13
- data/vendor/assets/src/medias/rubies/examples/clear.rb +0 -10
- data/vendor/assets/src/medias/rubies/examples/clone.rb +0 -35
- data/vendor/assets/src/medias/rubies/examples/code.rb +0 -11
- data/vendor/assets/src/medias/rubies/examples/color.rb +0 -73
- data/vendor/assets/src/medias/rubies/examples/create_atome_in_atome.rb +0 -13
- data/vendor/assets/src/medias/rubies/examples/cursor.rb +0 -7
- data/vendor/assets/src/medias/rubies/examples/delete.rb +0 -42
- data/vendor/assets/src/medias/rubies/examples/depth.rb +0 -6
- data/vendor/assets/src/medias/rubies/examples/detached.rb +0 -13
- data/vendor/assets/src/medias/rubies/examples/drag.rb +0 -98
- data/vendor/assets/src/medias/rubies/examples/drop.rb +0 -26
- data/vendor/assets/src/medias/rubies/examples/edit.rb +0 -12
- data/vendor/assets/src/medias/rubies/examples/element.rb +0 -6
- data/vendor/assets/src/medias/rubies/examples/empty_atome.rb +0 -12
- data/vendor/assets/src/medias/rubies/examples/fullscreen.rb +0 -15
- data/vendor/assets/src/medias/rubies/examples/grab.rb +0 -5
- data/vendor/assets/src/medias/rubies/examples/height.rb +0 -7
- data/vendor/assets/src/medias/rubies/examples/hide.rb +0 -7
- data/vendor/assets/src/medias/rubies/examples/id.rb +0 -14
- data/vendor/assets/src/medias/rubies/examples/image.rb +0 -8
- data/vendor/assets/src/medias/rubies/examples/left.rb +0 -7
- data/vendor/assets/src/medias/rubies/examples/link.rb +0 -22
- data/vendor/assets/src/medias/rubies/examples/markers.rb +0 -48
- data/vendor/assets/src/medias/rubies/examples/materials.rb +0 -15
- data/vendor/assets/src/medias/rubies/examples/matrix.rb +0 -102
- data/vendor/assets/src/medias/rubies/examples/matrix_changes.rb +0 -483
- data/vendor/assets/src/medias/rubies/examples/matrix_simple.rb +0 -32
- data/vendor/assets/src/medias/rubies/examples/monitoring.rb +0 -70
- data/vendor/assets/src/medias/rubies/examples/mute.rb +0 -22
- data/vendor/assets/src/medias/rubies/examples/on.rb +0 -26
- data/vendor/assets/src/medias/rubies/examples/opacity.rb +0 -5
- data/vendor/assets/src/medias/rubies/examples/over.rb +0 -21
- data/vendor/assets/src/medias/rubies/examples/pause.rb +0 -15
- data/vendor/assets/src/medias/rubies/examples/physical.rb +0 -19
- data/vendor/assets/src/medias/rubies/examples/play.rb +0 -15
- data/vendor/assets/src/medias/rubies/examples/read.rb +0 -11
- data/vendor/assets/src/medias/rubies/examples/refresh.rb +0 -8
- data/vendor/assets/src/medias/rubies/examples/remove.rb +0 -16
- data/vendor/assets/src/medias/rubies/examples/repeat.rb +0 -6
- data/vendor/assets/src/medias/rubies/examples/right.rb +0 -3
- data/vendor/assets/src/medias/rubies/examples/rotate.rb +0 -4
- data/vendor/assets/src/medias/rubies/examples/schedule.rb +0 -13
- data/vendor/assets/src/medias/rubies/examples/shadow.rb +0 -84
- data/vendor/assets/src/medias/rubies/examples/size.rb +0 -8
- data/vendor/assets/src/medias/rubies/examples/sort.rb +0 -18
- data/vendor/assets/src/medias/rubies/examples/style.rb +0 -4
- data/vendor/assets/src/medias/rubies/examples/tags.rb +0 -10
- data/vendor/assets/src/medias/rubies/examples/text.rb +0 -39
- data/vendor/assets/src/medias/rubies/examples/time.rb +0 -18
- data/vendor/assets/src/medias/rubies/examples/to_px.rb +0 -10
- data/vendor/assets/src/medias/rubies/examples/touch.rb +0 -56
- data/vendor/assets/src/medias/rubies/examples/vector.rb +0 -39
- data/vendor/assets/src/medias/rubies/examples/video.rb +0 -65
- data/vendor/assets/src/medias/rubies/examples/wait.rb +0 -8
- data/vendor/assets/src/medias/rubies/examples/web.rb +0 -13
- data/vendor/assets/src/medias/rubies/examples/width.rb +0 -6
- data/vendor/assets/src/medias/rubies/test.rb +0 -1
- data/vendor/assets/src/medias/rubies/text_read.rb +0 -1
- data/vendor/assets/src/medias/rubies/unstable/!run.rb +0 -16
- data/vendor/assets/src/medias/rubies/unstable/_2_solve.rb +0 -72
- data/vendor/assets/src/medias/rubies/unstable/_attach.rb +0 -12
- data/vendor/assets/src/medias/rubies/unstable/_audio.rb +0 -231
- data/vendor/assets/src/medias/rubies/unstable/_dataset.rb +0 -257
- data/vendor/assets/src/medias/rubies/unstable/_matrix.rb +0 -58
- data/vendor/assets/src/medias/rubies/unstable/_os.rb +0 -29
- data/vendor/assets/src/medias/rubies/unstable/_table2.rb +0 -108
- data/vendor/assets/src/medias/rubies/unstable/_vie.rb +0 -211
- data/vendor/assets/src/medias/rubies/users/code.rb +0 -6
- /data/lib/{atome/renderers → platform_specific}/opal/opal.rb +0 -0
- /data/lib/{atome/renderers → platform_specific}/opal/opal_parser.rb +0 -0
- /data/{vendor/assets/src/utilities/mode.rb → lib/renderers/html/communication.rb} +0 -0
- /data/{vendor/assets/src/medias/rubies/unstable/_test.rb → lib/renderers/html/security.rb} +0 -0
@@ -0,0 +1,233 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
new({ renderer: :html, method: :attach, type: :string }) do |parent_found, _user_proc|
|
4
|
+
html.append_to(parent_found)
|
5
|
+
end
|
6
|
+
|
7
|
+
new({ renderer: :html, method: :apply, type: :string }) do |parent_found, _user_proc|
|
8
|
+
|
9
|
+
# TODO : factorise code below between text and shape, especially shadow as code is written twice and identical
|
10
|
+
case parent_found.type
|
11
|
+
when :shadow
|
12
|
+
shadows_to_apply = { filter: [], boxShadow: [] }
|
13
|
+
shadow.each do |shadow_id_found|
|
14
|
+
shadow_found = grab(shadow_id_found)
|
15
|
+
red = shadow_found.red * 255
|
16
|
+
green = shadow_found.green * 255
|
17
|
+
blue = shadow_found.blue * 255
|
18
|
+
alpha = shadow_found.alpha
|
19
|
+
left = shadow_found.left
|
20
|
+
top = shadow_found.top
|
21
|
+
blur = shadow_found.blur
|
22
|
+
inset = :inset if shadow_found.invert
|
23
|
+
if shadow_found.option == :natural
|
24
|
+
shadows_to_apply[:filter] << "drop-shadow(#{left}px #{top}px #{blur}px rgba(#{red}, #{green}, #{blue}, #{alpha}))"
|
25
|
+
else
|
26
|
+
shadows_to_apply[:boxShadow] << "#{left}px #{top}px #{blur}px rgba(#{red}, #{green}, #{blue}, #{alpha}) #{inset}"
|
27
|
+
end
|
28
|
+
end
|
29
|
+
drop_shadow = shadows_to_apply[:filter].join(' ')
|
30
|
+
box_shadow = shadows_to_apply[:boxShadow].join(',')
|
31
|
+
html.style("transform", "translate3d(0, 0, 0)")
|
32
|
+
html.style("boxShadow", box_shadow)
|
33
|
+
html.style("filter", drop_shadow)
|
34
|
+
when :color
|
35
|
+
red = parent_found.red * 255
|
36
|
+
green = parent_found.green * 255
|
37
|
+
blue = parent_found.blue * 255
|
38
|
+
alpha = parent_found.alpha
|
39
|
+
html.style(:backgroundColor, "rgba(#{red}, #{green}, #{blue}, #{alpha})")
|
40
|
+
when :paint
|
41
|
+
|
42
|
+
# if when found colors when use it for the gradient , else whe use the colors within the current atome
|
43
|
+
# gradient_found = params[:colors] || @apply
|
44
|
+
# we get all the paint atomes applied to the current atome
|
45
|
+
gradients_to_apply = []
|
46
|
+
paint.each do |paint_id|
|
47
|
+
colors_to_apply = []
|
48
|
+
# now we get the paint atome
|
49
|
+
paint_atome = grab(paint_id)
|
50
|
+
paint_diffusion = paint_atome.diffusion
|
51
|
+
paint_direction = paint_atome.direction
|
52
|
+
diffusion = paint_diffusion || :linear
|
53
|
+
if paint_direction && paint_direction == :linear
|
54
|
+
direction = " to #{params[:direction]},"
|
55
|
+
elsif diffusion == :linear
|
56
|
+
direction = ' to bottom,'
|
57
|
+
end
|
58
|
+
|
59
|
+
direction = "#{paint_atome.rotate}deg," if paint_atome.rotate
|
60
|
+
|
61
|
+
# now we get the gradient and the color insied
|
62
|
+
paint_atome.gradient.each do |color_id|
|
63
|
+
color_found = grab(color_id)
|
64
|
+
red = color_found.red * 255
|
65
|
+
green = color_found.green * 255
|
66
|
+
blue = color_found.blue * 255
|
67
|
+
alpha = color_found.alpha
|
68
|
+
colors_to_apply << "rgba(#{red}, #{green}, #{blue}, #{alpha})"
|
69
|
+
end
|
70
|
+
colors_to_apply = colors_to_apply.join(',')
|
71
|
+
gradients_to_apply << "#{diffusion}-gradient(#{direction} #{colors_to_apply})"
|
72
|
+
end
|
73
|
+
# TODO : create complexe gradient staking the gradients uncommenting the line below
|
74
|
+
# beware the colors_to_apply syntax is incorrect for complexe gradient
|
75
|
+
# full_gradient_to_apply=gradients_to_apply.join(',')
|
76
|
+
full_gradient_to_apply = gradients_to_apply.last
|
77
|
+
html.style(:background, full_gradient_to_apply)
|
78
|
+
else
|
79
|
+
#
|
80
|
+
end
|
81
|
+
end
|
82
|
+
|
83
|
+
new({ renderer: :html, method: :apply, type: :string, specific: :text }) do |parent_found, _user_proc|
|
84
|
+
# TODO: we should treat objet when multiple : #{self.inspect}
|
85
|
+
case parent_found.type
|
86
|
+
when :shadow
|
87
|
+
shadows_to_apply = { filter: [], boxShadow: [] }
|
88
|
+
shadow.each do |shadow_id_found|
|
89
|
+
shadow_found = grab(shadow_id_found)
|
90
|
+
red = shadow_found.red * 255
|
91
|
+
green = shadow_found.green * 255
|
92
|
+
blue = shadow_found.blue * 255
|
93
|
+
alpha = shadow_found.alpha
|
94
|
+
left = shadow_found.left
|
95
|
+
top = shadow_found.top
|
96
|
+
blur = shadow_found.blur
|
97
|
+
inset = :inset if shadow_found.invert
|
98
|
+
if shadow_found.option == :natural
|
99
|
+
shadows_to_apply[:filter] << "drop-shadow(#{left}px #{top}px #{blur}px rgba(#{red}, #{green}, #{blue}, #{alpha}))"
|
100
|
+
else
|
101
|
+
shadows_to_apply[:boxShadow] << "#{left}px #{top}px #{blur}px rgba(#{red}, #{green}, #{blue}, #{alpha}) #{inset}"
|
102
|
+
end
|
103
|
+
end
|
104
|
+
drop_shadow = shadows_to_apply[:filter].join(' ')
|
105
|
+
box_shadow = shadows_to_apply[:boxShadow].join(',')
|
106
|
+
html.style("transform", "translate3d(0, 0, 0)")
|
107
|
+
html.style("boxShadow", box_shadow)
|
108
|
+
html.style("filter", drop_shadow)
|
109
|
+
when :color
|
110
|
+
red = parent_found.red * 255
|
111
|
+
green = parent_found.green * 255
|
112
|
+
blue = parent_found.blue * 255
|
113
|
+
alpha = parent_found.alpha
|
114
|
+
html.style(:color, "rgba(#{red}, #{green}, #{blue}, #{alpha})")
|
115
|
+
when :paint
|
116
|
+
# if when found colors when use it for the gradient , else whe use the colors within the current atome
|
117
|
+
# gradient_found = params[:colors] || @apply
|
118
|
+
# we get all the paint atomes applied to the current atome
|
119
|
+
gradients_to_apply = []
|
120
|
+
paint.each do |paint_id|
|
121
|
+
colors_to_apply = []
|
122
|
+
# now we get the paint atome
|
123
|
+
paint_atome = grab(paint_id)
|
124
|
+
paint_diffusion = paint_atome.diffusion
|
125
|
+
paint_direction = paint_atome.direction
|
126
|
+
diffusion = paint_diffusion || :linear
|
127
|
+
if paint_direction && paint_direction == :linear
|
128
|
+
direction = " to #{params[:direction]},"
|
129
|
+
elsif diffusion == :linear
|
130
|
+
direction = ' to bottom,'
|
131
|
+
end
|
132
|
+
|
133
|
+
if paint_atome.rotate
|
134
|
+
direction = "#{paint_atome.rotate}deg,"
|
135
|
+
end
|
136
|
+
|
137
|
+
# now we get the gradient and the color insied
|
138
|
+
paint_atome.gradient.each do |color_id|
|
139
|
+
color_found = grab(color_id)
|
140
|
+
red = color_found.red * 255
|
141
|
+
green = color_found.green * 255
|
142
|
+
blue = color_found.blue * 255
|
143
|
+
alpha = color_found.alpha
|
144
|
+
colors_to_apply << "rgba(#{red}, #{green}, #{blue}, #{alpha})"
|
145
|
+
end
|
146
|
+
colors_to_apply = colors_to_apply.join(',')
|
147
|
+
gradients_to_apply << "#{diffusion}-gradient(#{direction} #{colors_to_apply})"
|
148
|
+
end
|
149
|
+
# TODO : create complexe gradient staking the gradients uncommenting the line below
|
150
|
+
# beware the colors_to_apply syntax is incorrect for complexe gradient
|
151
|
+
# full_gradient_to_apply=gradients_to_apply.join(',')
|
152
|
+
full_gradient_to_apply = gradients_to_apply.last
|
153
|
+
|
154
|
+
html.style(:backgroundClip, 'text')
|
155
|
+
html.style(:color, 'transparent')
|
156
|
+
html.style(:backgroundImage, full_gradient_to_apply)
|
157
|
+
end
|
158
|
+
|
159
|
+
end
|
160
|
+
|
161
|
+
new({ renderer: :html, method: :apply, type: :string, specific: :vector }) do |parent_found, _user_proc|
|
162
|
+
|
163
|
+
# TODO : factorise code below between text and shape, especially shadow as code is written twice and identical
|
164
|
+
case parent_found.type
|
165
|
+
when :shadow
|
166
|
+
shadows_to_apply = { filter: [], boxShadow: [] }
|
167
|
+
shadow.each do |shadow_id_found|
|
168
|
+
shadow_found = grab(shadow_id_found)
|
169
|
+
red = shadow_found.red * 255
|
170
|
+
green = shadow_found.green * 255
|
171
|
+
blue = shadow_found.blue * 255
|
172
|
+
alpha = shadow_found.alpha
|
173
|
+
left = shadow_found.left
|
174
|
+
top = shadow_found.top
|
175
|
+
blur = shadow_found.blur
|
176
|
+
inset = :inset if shadow_found.invert
|
177
|
+
if shadow_found.option == :natural
|
178
|
+
shadows_to_apply[:filter] << "drop-shadow(#{left}px #{top}px #{blur}px rgba(#{red}, #{green}, #{blue}, #{alpha}))"
|
179
|
+
else
|
180
|
+
shadows_to_apply[:boxShadow] << "#{left}px #{top}px #{blur}px rgba(#{red}, #{green}, #{blue}, #{alpha}) #{inset}"
|
181
|
+
end
|
182
|
+
end
|
183
|
+
drop_shadow = shadows_to_apply[:filter].join(' ')
|
184
|
+
box_shadow = shadows_to_apply[:boxShadow].join(',')
|
185
|
+
html.style("transform", "translate3d(0, 0, 0)")
|
186
|
+
html.style("boxShadow", box_shadow)
|
187
|
+
html.style("filter", drop_shadow)
|
188
|
+
when :color
|
189
|
+
red = parent_found.red * 255
|
190
|
+
green = parent_found.green * 255
|
191
|
+
blue = parent_found.blue * 255
|
192
|
+
alpha = parent_found.alpha
|
193
|
+
html.colorize_svg_data("rgba(#{red}, #{green}, #{blue}, #{alpha})")
|
194
|
+
when :paint
|
195
|
+
|
196
|
+
# if when found colors when use it for the gradient , else whe use the colors within the current atome
|
197
|
+
# gradient_found = params[:colors] || @apply
|
198
|
+
# we get all the paint atomes applied to the current atome
|
199
|
+
gradients_to_apply = []
|
200
|
+
paint.each do |paint_id|
|
201
|
+
colors_to_apply = []
|
202
|
+
# now we get the paint atome
|
203
|
+
paint_atome = grab(paint_id)
|
204
|
+
paint_diffusion = paint_atome.diffusion
|
205
|
+
paint_direction = paint_atome.direction
|
206
|
+
diffusion = paint_diffusion || :linear
|
207
|
+
if paint_direction && paint_direction == :linear
|
208
|
+
direction = " to #{params[:direction]},"
|
209
|
+
elsif diffusion == :linear
|
210
|
+
direction = ' to bottom,'
|
211
|
+
end
|
212
|
+
|
213
|
+
direction = "#{paint_atome.rotate}deg," if paint_atome.rotate
|
214
|
+
|
215
|
+
# now we get the gradient and the color insied
|
216
|
+
paint_atome.gradient.each do |color_id|
|
217
|
+
color_found = grab(color_id)
|
218
|
+
red = color_found.red * 255
|
219
|
+
green = color_found.green * 255
|
220
|
+
blue = color_found.blue * 255
|
221
|
+
alpha = color_found.alpha
|
222
|
+
colors_to_apply << "rgba(#{red}, #{green}, #{blue}, #{alpha})"
|
223
|
+
end
|
224
|
+
colors_to_apply = colors_to_apply.join(',')
|
225
|
+
gradients_to_apply << "#{diffusion}-gradient(#{direction} #{colors_to_apply})"
|
226
|
+
end
|
227
|
+
# TODO : create complexe gradient staking the gradients uncommenting the line below
|
228
|
+
# beware the colors_to_apply syntax is incorrect for complexe gradient
|
229
|
+
# full_gradient_to_apply=gradients_to_apply.join(',')
|
230
|
+
full_gradient_to_apply = gradients_to_apply.last
|
231
|
+
html.style(:background, full_gradient_to_apply)
|
232
|
+
end
|
233
|
+
end
|