matestack-ui-core 1.5.0 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE +17 -5
- data/README.md +78 -115
- data/Rakefile +0 -2
- data/lib/matestack/ui/app.rb +1 -0
- data/lib/matestack/ui/component.rb +1 -0
- data/lib/matestack/ui/core.rb +58 -10
- data/lib/matestack/ui/core/app.rb +36 -0
- data/lib/matestack/ui/core/base.rb +109 -0
- data/lib/matestack/ui/core/component.rb +8 -0
- data/lib/matestack/ui/core/context.rb +17 -0
- data/lib/matestack/ui/core/helper.rb +91 -0
- data/lib/matestack/ui/core/page.rb +63 -0
- data/lib/matestack/ui/core/properties.rb +105 -0
- data/lib/matestack/ui/core/slots.rb +15 -0
- data/lib/matestack/ui/core/tag_helper.rb +94 -0
- data/lib/matestack/ui/core/version.rb +1 -1
- data/lib/matestack/ui/core/vue_attributes.rb +13 -0
- data/lib/matestack/ui/page.rb +1 -0
- data/{app/concepts/matestack/ui/core → lib/matestack/ui/vue_js}/app/app.js +2 -3
- data/{app/concepts/matestack/ui/core → lib/matestack/ui/vue_js}/app/location.js +0 -0
- data/{app/concepts/matestack/ui/core → lib/matestack/ui/vue_js}/app/store.js +1 -1
- data/lib/matestack/ui/vue_js/components.rb +94 -0
- data/lib/matestack/ui/vue_js/components/action.js +151 -0
- data/lib/matestack/ui/vue_js/components/action.rb +46 -0
- data/{app/concepts/matestack/ui/core/async → lib/matestack/ui/vue_js/components}/async.js +22 -22
- data/lib/matestack/ui/vue_js/components/async.rb +84 -0
- data/{app/concepts/matestack/ui/core/cable → lib/matestack/ui/vue_js/components}/cable.js +14 -14
- data/lib/matestack/ui/vue_js/components/cable.rb +69 -0
- data/{app/concepts/matestack/ui/core/collection/content → lib/matestack/ui/vue_js/components/collection}/content.js +21 -22
- data/lib/matestack/ui/vue_js/components/collection/content.rb +32 -0
- data/lib/matestack/ui/vue_js/components/collection/filter.js +45 -0
- data/lib/matestack/ui/vue_js/components/collection/filter.rb +29 -0
- data/lib/matestack/ui/vue_js/components/collection/filter_reset.rb +19 -0
- data/{app/concepts/matestack/ui/core → lib/matestack/ui/vue_js/components}/collection/helper.rb +66 -65
- data/lib/matestack/ui/vue_js/components/collection/next.rb +19 -0
- data/lib/matestack/ui/vue_js/components/collection/order.js +46 -0
- data/lib/matestack/ui/vue_js/components/collection/order.rb +28 -0
- data/lib/matestack/ui/vue_js/components/collection/order_toggle.rb +21 -0
- data/lib/matestack/ui/vue_js/components/collection/order_toggle_indicator.rb +30 -0
- data/lib/matestack/ui/vue_js/components/collection/page.rb +21 -0
- data/lib/matestack/ui/vue_js/components/collection/previous.rb +19 -0
- data/lib/matestack/ui/vue_js/components/form/base.rb +167 -0
- data/{app/concepts/matestack/ui/core/form/checkbox → lib/matestack/ui/vue_js/components/form}/checkbox.js +2 -2
- data/lib/matestack/ui/vue_js/components/form/checkbox.rb +105 -0
- data/{app/concepts/matestack/ui/core/form/checkbox/mixin.js → lib/matestack/ui/vue_js/components/form/checkbox_mixin.js} +5 -2
- data/lib/matestack/ui/vue_js/components/form/context.rb +15 -0
- data/{app/concepts/matestack/ui/core → lib/matestack/ui/vue_js/components}/form/form.js +53 -53
- data/lib/matestack/ui/vue_js/components/form/form.rb +64 -0
- data/{app/concepts/matestack/ui/core/form/input → lib/matestack/ui/vue_js/components/form}/input.js +2 -2
- data/lib/matestack/ui/vue_js/components/form/input.rb +37 -0
- data/{app/concepts/matestack/ui/core/form/input/mixin.js → lib/matestack/ui/vue_js/components/form/input_mixin.js} +5 -2
- data/{app/concepts/matestack/ui/core/form/radio → lib/matestack/ui/vue_js/components/form}/radio.js +2 -2
- data/lib/matestack/ui/vue_js/components/form/radio.rb +76 -0
- data/{app/concepts/matestack/ui/core/form/radio/mixin.js → lib/matestack/ui/vue_js/components/form/radio_mixin.js} +4 -1
- data/{app/concepts/matestack/ui/core/form/select → lib/matestack/ui/vue_js/components/form}/select.js +2 -2
- data/lib/matestack/ui/vue_js/components/form/select.rb +88 -0
- data/{app/concepts/matestack/ui/core/form/select/mixin.js → lib/matestack/ui/vue_js/components/form/select_mixin.js} +5 -2
- data/{app/concepts/matestack/ui/core/form/textarea → lib/matestack/ui/vue_js/components/form}/textarea.js +2 -2
- data/lib/matestack/ui/vue_js/components/form/textarea.rb +37 -0
- data/{app/concepts/matestack/ui/core/form/textarea/mixin.js → lib/matestack/ui/vue_js/components/form/textarea_mixin.js} +5 -2
- data/{app/concepts/matestack/ui/core/isolated → lib/matestack/ui/vue_js/components}/isolated.js +19 -19
- data/lib/matestack/ui/vue_js/components/isolated.rb +86 -0
- data/{app/concepts/matestack/ui/core/component/component.js → lib/matestack/ui/vue_js/components/mixin.js} +2 -2
- data/{app/concepts/matestack/ui/core/onclick → lib/matestack/ui/vue_js/components}/onclick.js +3 -4
- data/lib/matestack/ui/vue_js/components/onclick.rb +37 -0
- data/{app/concepts/matestack/ui/core/toggle → lib/matestack/ui/vue_js/components}/toggle.js +17 -17
- data/lib/matestack/ui/vue_js/components/toggle.rb +38 -0
- data/{app/concepts/matestack/ui/core/transition → lib/matestack/ui/vue_js/components}/transition.js +6 -6
- data/lib/matestack/ui/vue_js/components/transition.rb +40 -0
- data/lib/matestack/ui/vue_js/event_hub.js +5 -0
- data/{app/concepts/matestack/ui/core/js/helpers/query-params-helper.js → lib/matestack/ui/vue_js/helpers/query_params_helper.js} +0 -0
- data/lib/matestack/ui/vue_js/index.js +52 -0
- data/lib/matestack/ui/vue_js/initialize.rb +5 -0
- data/{app/concepts/matestack/ui/core/page/content → lib/matestack/ui/vue_js/page}/content.js +1 -1
- data/lib/matestack/ui/vue_js/vue.rb +63 -0
- data/lib/matestack/ui/vue_js_component.rb +2 -0
- metadata +75 -404
- data/app/concepts/matestack/ui/core/abbr/abbr.haml +0 -5
- data/app/concepts/matestack/ui/core/abbr/abbr.rb +0 -5
- data/app/concepts/matestack/ui/core/action/action.haml +0 -3
- data/app/concepts/matestack/ui/core/action/action.js +0 -152
- data/app/concepts/matestack/ui/core/action/action.rb +0 -80
- data/app/concepts/matestack/ui/core/actionview/dynamic.haml +0 -6
- data/app/concepts/matestack/ui/core/actionview/dynamic.rb +0 -28
- data/app/concepts/matestack/ui/core/actionview/static.haml +0 -1
- data/app/concepts/matestack/ui/core/actionview/static.rb +0 -28
- data/app/concepts/matestack/ui/core/address/address.haml +0 -5
- data/app/concepts/matestack/ui/core/address/address.rb +0 -5
- data/app/concepts/matestack/ui/core/app/app.haml +0 -3
- data/app/concepts/matestack/ui/core/app/app.rb +0 -51
- data/app/concepts/matestack/ui/core/area/area.haml +0 -1
- data/app/concepts/matestack/ui/core/area/area.rb +0 -6
- data/app/concepts/matestack/ui/core/article/article.haml +0 -5
- data/app/concepts/matestack/ui/core/article/article.rb +0 -5
- data/app/concepts/matestack/ui/core/aside/aside.haml +0 -3
- data/app/concepts/matestack/ui/core/aside/aside.rb +0 -4
- data/app/concepts/matestack/ui/core/async/async.haml +0 -6
- data/app/concepts/matestack/ui/core/async/async.rb +0 -37
- data/app/concepts/matestack/ui/core/async/children_wrapper.haml +0 -2
- data/app/concepts/matestack/ui/core/b/b.haml +0 -5
- data/app/concepts/matestack/ui/core/b/b.rb +0 -5
- data/app/concepts/matestack/ui/core/bdi/bdi.haml +0 -5
- data/app/concepts/matestack/ui/core/bdi/bdi.rb +0 -5
- data/app/concepts/matestack/ui/core/bdo/bdo.haml +0 -5
- data/app/concepts/matestack/ui/core/bdo/bdo.rb +0 -6
- data/app/concepts/matestack/ui/core/blockquote/blockquote.haml +0 -5
- data/app/concepts/matestack/ui/core/blockquote/blockquote.rb +0 -6
- data/app/concepts/matestack/ui/core/br/br.haml +0 -5
- data/app/concepts/matestack/ui/core/br/br.rb +0 -5
- data/app/concepts/matestack/ui/core/button/button.haml +0 -5
- data/app/concepts/matestack/ui/core/button/button.rb +0 -7
- data/app/concepts/matestack/ui/core/cable/cable.haml +0 -4
- data/app/concepts/matestack/ui/core/cable/cable.rb +0 -28
- data/app/concepts/matestack/ui/core/cable/children_wrapper.haml +0 -2
- data/app/concepts/matestack/ui/core/caption/caption.haml +0 -5
- data/app/concepts/matestack/ui/core/caption/caption.rb +0 -5
- data/app/concepts/matestack/ui/core/cite/cite.haml +0 -5
- data/app/concepts/matestack/ui/core/cite/cite.rb +0 -5
- data/app/concepts/matestack/ui/core/code/code.haml +0 -5
- data/app/concepts/matestack/ui/core/code/code.rb +0 -5
- data/app/concepts/matestack/ui/core/collection/content/content.rb +0 -16
- data/app/concepts/matestack/ui/core/collection/content/next/next.haml +0 -3
- data/app/concepts/matestack/ui/core/collection/content/next/next.rb +0 -5
- data/app/concepts/matestack/ui/core/collection/content/page/link/link.haml +0 -3
- data/app/concepts/matestack/ui/core/collection/content/page/link/link.rb +0 -7
- data/app/concepts/matestack/ui/core/collection/content/previous/previous.haml +0 -3
- data/app/concepts/matestack/ui/core/collection/content/previous/previous.rb +0 -5
- data/app/concepts/matestack/ui/core/collection/filter/filter.js +0 -48
- data/app/concepts/matestack/ui/core/collection/filter/filter.rb +0 -16
- data/app/concepts/matestack/ui/core/collection/filter/input/input.rb +0 -28
- data/app/concepts/matestack/ui/core/collection/filter/reset/reset.haml +0 -3
- data/app/concepts/matestack/ui/core/collection/filter/reset/reset.rb +0 -5
- data/app/concepts/matestack/ui/core/collection/filter/select/select.haml +0 -10
- data/app/concepts/matestack/ui/core/collection/filter/select/select.rb +0 -30
- data/app/concepts/matestack/ui/core/collection/filter/submit/submit.haml +0 -3
- data/app/concepts/matestack/ui/core/collection/filter/submit/submit.rb +0 -5
- data/app/concepts/matestack/ui/core/collection/order/order.js +0 -56
- data/app/concepts/matestack/ui/core/collection/order/order.rb +0 -16
- data/app/concepts/matestack/ui/core/collection/order/toggle/indicator/indicator.rb +0 -17
- data/app/concepts/matestack/ui/core/collection/order/toggle/toggle.haml +0 -3
- data/app/concepts/matestack/ui/core/collection/order/toggle/toggle.rb +0 -4
- data/app/concepts/matestack/ui/core/component/anonym-dynamic-component.js +0 -10
- data/app/concepts/matestack/ui/core/component/base.rb +0 -430
- data/app/concepts/matestack/ui/core/component/children.haml +0 -2
- data/app/concepts/matestack/ui/core/component/dynamic.haml +0 -6
- data/app/concepts/matestack/ui/core/component/dynamic.rb +0 -47
- data/app/concepts/matestack/ui/core/component/dynamic_without_rerender.haml +0 -2
- data/app/concepts/matestack/ui/core/component/static.rb +0 -7
- data/app/concepts/matestack/ui/core/data/data.haml +0 -5
- data/app/concepts/matestack/ui/core/data/data.rb +0 -6
- data/app/concepts/matestack/ui/core/datalist/datalist.haml +0 -3
- data/app/concepts/matestack/ui/core/datalist/datalist.rb +0 -4
- data/app/concepts/matestack/ui/core/dd/dd.haml +0 -5
- data/app/concepts/matestack/ui/core/dd/dd.rb +0 -5
- data/app/concepts/matestack/ui/core/del/del.haml +0 -5
- data/app/concepts/matestack/ui/core/del/del.rb +0 -6
- data/app/concepts/matestack/ui/core/details/details.haml +0 -3
- data/app/concepts/matestack/ui/core/details/details.rb +0 -5
- data/app/concepts/matestack/ui/core/dfn/dfn.haml +0 -5
- data/app/concepts/matestack/ui/core/dfn/dfn.rb +0 -6
- data/app/concepts/matestack/ui/core/dialog/dialog.haml +0 -5
- data/app/concepts/matestack/ui/core/dialog/dialog.rb +0 -6
- data/app/concepts/matestack/ui/core/div/div.haml +0 -3
- data/app/concepts/matestack/ui/core/div/div.rb +0 -4
- data/app/concepts/matestack/ui/core/dl/dl.haml +0 -5
- data/app/concepts/matestack/ui/core/dl/dl.rb +0 -5
- data/app/concepts/matestack/ui/core/dt/dt.haml +0 -5
- data/app/concepts/matestack/ui/core/dt/dt.rb +0 -5
- data/app/concepts/matestack/ui/core/em/em.haml +0 -5
- data/app/concepts/matestack/ui/core/em/em.rb +0 -5
- data/app/concepts/matestack/ui/core/fieldset/fieldset.haml +0 -5
- data/app/concepts/matestack/ui/core/fieldset/fieldset.rb +0 -6
- data/app/concepts/matestack/ui/core/figure/figure.haml +0 -3
- data/app/concepts/matestack/ui/core/figure/figure.rb +0 -4
- data/app/concepts/matestack/ui/core/footer/footer.haml +0 -3
- data/app/concepts/matestack/ui/core/footer/footer.rb +0 -4
- data/app/concepts/matestack/ui/core/form/checkbox/base.rb +0 -120
- data/app/concepts/matestack/ui/core/form/checkbox/checkbox.rb +0 -16
- data/app/concepts/matestack/ui/core/form/form.haml +0 -2
- data/app/concepts/matestack/ui/core/form/form.rb +0 -104
- data/app/concepts/matestack/ui/core/form/has_errors.rb +0 -54
- data/app/concepts/matestack/ui/core/form/has_input_html_attributes.rb +0 -13
- data/app/concepts/matestack/ui/core/form/input/base.rb +0 -75
- data/app/concepts/matestack/ui/core/form/input/input.rb +0 -17
- data/app/concepts/matestack/ui/core/form/radio/base.rb +0 -90
- data/app/concepts/matestack/ui/core/form/radio/radio.rb +0 -16
- data/app/concepts/matestack/ui/core/form/select/base.rb +0 -98
- data/app/concepts/matestack/ui/core/form/select/select.rb +0 -19
- data/app/concepts/matestack/ui/core/form/submit/base.rb +0 -12
- data/app/concepts/matestack/ui/core/form/submit/submit.js +0 -19
- data/app/concepts/matestack/ui/core/form/submit/submit.rb +0 -15
- data/app/concepts/matestack/ui/core/form/textarea/base.rb +0 -49
- data/app/concepts/matestack/ui/core/form/textarea/textarea.rb +0 -17
- data/app/concepts/matestack/ui/core/form/utils.rb +0 -47
- data/app/concepts/matestack/ui/core/header/header.haml +0 -3
- data/app/concepts/matestack/ui/core/header/header.rb +0 -4
- data/app/concepts/matestack/ui/core/heading/heading.haml +0 -5
- data/app/concepts/matestack/ui/core/heading/heading.rb +0 -5
- data/app/concepts/matestack/ui/core/hr/hr.haml +0 -1
- data/app/concepts/matestack/ui/core/hr/hr.rb +0 -4
- data/app/concepts/matestack/ui/core/icon/icon.haml +0 -5
- data/app/concepts/matestack/ui/core/icon/icon.rb +0 -5
- data/app/concepts/matestack/ui/core/iframe/iframe.haml +0 -5
- data/app/concepts/matestack/ui/core/iframe/iframe.rb +0 -7
- data/app/concepts/matestack/ui/core/img/img.haml +0 -1
- data/app/concepts/matestack/ui/core/img/img.rb +0 -15
- data/app/concepts/matestack/ui/core/input/input.haml +0 -1
- data/app/concepts/matestack/ui/core/input/input.rb +0 -9
- data/app/concepts/matestack/ui/core/ins/ins.haml +0 -5
- data/app/concepts/matestack/ui/core/ins/ins.rb +0 -6
- data/app/concepts/matestack/ui/core/isolated/children_wrapper.haml +0 -2
- data/app/concepts/matestack/ui/core/isolated/isolated.haml +0 -10
- data/app/concepts/matestack/ui/core/isolated/isolated.rb +0 -59
- data/app/concepts/matestack/ui/core/js/core.js +0 -66
- data/app/concepts/matestack/ui/core/js/event-hub.js +0 -5
- data/app/concepts/matestack/ui/core/kbd/kbd.haml +0 -5
- data/app/concepts/matestack/ui/core/kbd/kbd.rb +0 -5
- data/app/concepts/matestack/ui/core/label/label.haml +0 -5
- data/app/concepts/matestack/ui/core/label/label.rb +0 -6
- data/app/concepts/matestack/ui/core/legend/legend.haml +0 -5
- data/app/concepts/matestack/ui/core/legend/legend.rb +0 -5
- data/app/concepts/matestack/ui/core/li/li.haml +0 -5
- data/app/concepts/matestack/ui/core/li/li.rb +0 -6
- data/app/concepts/matestack/ui/core/link/link.haml +0 -5
- data/app/concepts/matestack/ui/core/link/link.rb +0 -23
- data/app/concepts/matestack/ui/core/main/main.haml +0 -3
- data/app/concepts/matestack/ui/core/main/main.rb +0 -4
- data/app/concepts/matestack/ui/core/map/map.haml +0 -3
- data/app/concepts/matestack/ui/core/map/map.rb +0 -5
- data/app/concepts/matestack/ui/core/mark/mark.haml +0 -5
- data/app/concepts/matestack/ui/core/mark/mark.rb +0 -5
- data/app/concepts/matestack/ui/core/meter/meter.haml +0 -4
- data/app/concepts/matestack/ui/core/meter/meter.rb +0 -5
- data/app/concepts/matestack/ui/core/nav/nav.haml +0 -3
- data/app/concepts/matestack/ui/core/nav/nav.rb +0 -4
- data/app/concepts/matestack/ui/core/noscript/noscript.haml +0 -5
- data/app/concepts/matestack/ui/core/noscript/noscript.rb +0 -5
- data/app/concepts/matestack/ui/core/object/object.haml +0 -1
- data/app/concepts/matestack/ui/core/object/object.rb +0 -5
- data/app/concepts/matestack/ui/core/ol/ol.haml +0 -3
- data/app/concepts/matestack/ui/core/ol/ol.rb +0 -5
- data/app/concepts/matestack/ui/core/onclick/onclick.haml +0 -2
- data/app/concepts/matestack/ui/core/onclick/onclick.rb +0 -6
- data/app/concepts/matestack/ui/core/optgroup/optgroup.haml +0 -3
- data/app/concepts/matestack/ui/core/optgroup/optgroup.rb +0 -5
- data/app/concepts/matestack/ui/core/option/option.haml +0 -5
- data/app/concepts/matestack/ui/core/option/option.rb +0 -6
- data/app/concepts/matestack/ui/core/output/output.haml +0 -5
- data/app/concepts/matestack/ui/core/output/output.rb +0 -6
- data/app/concepts/matestack/ui/core/page/content/content.rb +0 -28
- data/app/concepts/matestack/ui/core/page/page.haml +0 -3
- data/app/concepts/matestack/ui/core/page/page.rb +0 -30
- data/app/concepts/matestack/ui/core/paragraph/paragraph.haml +0 -5
- data/app/concepts/matestack/ui/core/paragraph/paragraph.rb +0 -5
- data/app/concepts/matestack/ui/core/param/param.haml +0 -1
- data/app/concepts/matestack/ui/core/param/param.rb +0 -5
- data/app/concepts/matestack/ui/core/partial/partial.haml +0 -2
- data/app/concepts/matestack/ui/core/partial/partial.rb +0 -4
- data/app/concepts/matestack/ui/core/picture/picture.haml +0 -3
- data/app/concepts/matestack/ui/core/picture/picture.rb +0 -4
- data/app/concepts/matestack/ui/core/plain/plain.rb +0 -9
- data/app/concepts/matestack/ui/core/pre/pre.haml +0 -5
- data/app/concepts/matestack/ui/core/pre/pre.rb +0 -5
- data/app/concepts/matestack/ui/core/progress/progress.haml +0 -3
- data/app/concepts/matestack/ui/core/progress/progress.rb +0 -5
- data/app/concepts/matestack/ui/core/q/q.haml +0 -5
- data/app/concepts/matestack/ui/core/q/q.rb +0 -6
- data/app/concepts/matestack/ui/core/rp/rp.haml +0 -5
- data/app/concepts/matestack/ui/core/rp/rp.rb +0 -5
- data/app/concepts/matestack/ui/core/rt/rt.haml +0 -5
- data/app/concepts/matestack/ui/core/rt/rt.rb +0 -5
- data/app/concepts/matestack/ui/core/ruby/ruby.haml +0 -5
- data/app/concepts/matestack/ui/core/ruby/ruby.rb +0 -5
- data/app/concepts/matestack/ui/core/s/s.haml +0 -5
- data/app/concepts/matestack/ui/core/s/s.rb +0 -6
- data/app/concepts/matestack/ui/core/samp/samp.haml +0 -5
- data/app/concepts/matestack/ui/core/samp/samp.rb +0 -5
- data/app/concepts/matestack/ui/core/section/section.haml +0 -3
- data/app/concepts/matestack/ui/core/section/section.rb +0 -4
- data/app/concepts/matestack/ui/core/select/select.haml +0 -3
- data/app/concepts/matestack/ui/core/select/select.rb +0 -7
- data/app/concepts/matestack/ui/core/slot/slot.haml +0 -2
- data/app/concepts/matestack/ui/core/slot/slot.rb +0 -4
- data/app/concepts/matestack/ui/core/small/small.haml +0 -5
- data/app/concepts/matestack/ui/core/small/small.rb +0 -5
- data/app/concepts/matestack/ui/core/span/span.haml +0 -5
- data/app/concepts/matestack/ui/core/span/span.rb +0 -5
- data/app/concepts/matestack/ui/core/strong/strong.haml +0 -5
- data/app/concepts/matestack/ui/core/strong/strong.rb +0 -5
- data/app/concepts/matestack/ui/core/sub/sub.haml +0 -5
- data/app/concepts/matestack/ui/core/sub/sub.rb +0 -5
- data/app/concepts/matestack/ui/core/summary/summary.haml +0 -5
- data/app/concepts/matestack/ui/core/summary/summary.rb +0 -5
- data/app/concepts/matestack/ui/core/sup/sup.haml +0 -5
- data/app/concepts/matestack/ui/core/sup/sup.rb +0 -5
- data/app/concepts/matestack/ui/core/table/table.haml +0 -3
- data/app/concepts/matestack/ui/core/table/table.rb +0 -4
- data/app/concepts/matestack/ui/core/tbody/tbody.haml +0 -3
- data/app/concepts/matestack/ui/core/tbody/tbody.rb +0 -4
- data/app/concepts/matestack/ui/core/td/td.haml +0 -5
- data/app/concepts/matestack/ui/core/td/td.rb +0 -6
- data/app/concepts/matestack/ui/core/template/template.haml +0 -3
- data/app/concepts/matestack/ui/core/template/template.rb +0 -4
- data/app/concepts/matestack/ui/core/textarea/textarea.haml +0 -5
- data/app/concepts/matestack/ui/core/textarea/textarea.rb +0 -10
- data/app/concepts/matestack/ui/core/tfoot/tfoot.haml +0 -3
- data/app/concepts/matestack/ui/core/tfoot/tfoot.rb +0 -4
- data/app/concepts/matestack/ui/core/th/th.haml +0 -5
- data/app/concepts/matestack/ui/core/th/th.rb +0 -6
- data/app/concepts/matestack/ui/core/thead/thead.haml +0 -3
- data/app/concepts/matestack/ui/core/thead/thead.rb +0 -4
- data/app/concepts/matestack/ui/core/time/time.haml +0 -3
- data/app/concepts/matestack/ui/core/time/time.rb +0 -5
- data/app/concepts/matestack/ui/core/toggle/toggle.haml +0 -2
- data/app/concepts/matestack/ui/core/toggle/toggle.rb +0 -13
- data/app/concepts/matestack/ui/core/tr/tr.haml +0 -3
- data/app/concepts/matestack/ui/core/tr/tr.rb +0 -4
- data/app/concepts/matestack/ui/core/transition/transition.haml +0 -5
- data/app/concepts/matestack/ui/core/transition/transition.rb +0 -38
- data/app/concepts/matestack/ui/core/u/u.haml +0 -5
- data/app/concepts/matestack/ui/core/u/u.rb +0 -6
- data/app/concepts/matestack/ui/core/ul/ul.haml +0 -3
- data/app/concepts/matestack/ui/core/ul/ul.rb +0 -4
- data/app/concepts/matestack/ui/core/unescaped/unescaped.rb +0 -9
- data/app/concepts/matestack/ui/core/var/var.haml +0 -5
- data/app/concepts/matestack/ui/core/var/var.rb +0 -5
- data/app/concepts/matestack/ui/core/video/video.haml +0 -3
- data/app/concepts/matestack/ui/core/video/video.rb +0 -13
- data/app/concepts/matestack/ui/core/view/view.haml +0 -1
- data/app/concepts/matestack/ui/core/view/view.rb +0 -30
- data/app/concepts/matestack/ui/core/wbr/wbr.haml +0 -5
- data/app/concepts/matestack/ui/core/wbr/wbr.rb +0 -5
- data/app/concepts/matestack/ui/core/youtube/youtube.haml +0 -1
- data/app/concepts/matestack/ui/core/youtube/youtube.rb +0 -28
- data/app/helpers/matestack/ui/core/application_helper.rb +0 -111
- data/app/javascript/matestack-ui-core/index.js +0 -32
- data/app/javascript/matestack-ui-core/styles/index.scss +0 -5
- data/app/javascript/packs/matestack-ui-core.js +0 -8
- data/app/lib/matestack/ui/app.rb +0 -1
- data/app/lib/matestack/ui/component.rb +0 -1
- data/app/lib/matestack/ui/core/has_view_context.rb +0 -16
- data/app/lib/matestack/ui/core/html_attributes.rb +0 -43
- data/app/lib/matestack/ui/core/properties.rb +0 -161
- data/app/lib/matestack/ui/core/rendering/default_renderer_class_determiner.rb +0 -33
- data/app/lib/matestack/ui/core/rendering/main_renderer.rb +0 -203
- data/app/lib/matestack/ui/dynamic_actionview_component.rb +0 -1
- data/app/lib/matestack/ui/dynamic_component.rb +0 -1
- data/app/lib/matestack/ui/isolated_component.rb +0 -1
- data/app/lib/matestack/ui/page.rb +0 -1
- data/app/lib/matestack/ui/static_actionview_component.rb +0 -1
- data/app/lib/matestack/ui/static_component.rb +0 -1
- data/app/lib/matestack/ui/vue_js_component.rb +0 -1
- data/config/routes.rb +0 -2
- data/lib/generators/matestack/app/USAGE +0 -21
- data/lib/generators/matestack/app/app_generator.rb +0 -25
- data/lib/generators/matestack/app/templates/app/controllers/%file_name%_controller.rb.tt +0 -5
- data/lib/generators/matestack/app/templates/app/matestack/apps/%file_name%.rb.tt +0 -28
- data/lib/generators/matestack/component/USAGE +0 -20
- data/lib/generators/matestack/component/component_generator.rb +0 -29
- data/lib/generators/matestack/component/templates/app/matestack/components/%namespace%/%file_name%.haml.tt +0 -5
- data/lib/generators/matestack/component/templates/app/matestack/components/%namespace%/%file_name%.js.tt +0 -17
- data/lib/generators/matestack/component/templates/app/matestack/components/%namespace%/%file_name%.rb.tt +0 -11
- data/lib/generators/matestack/component/templates/app/matestack/components/%namespace%/%file_name%.scss.tt +0 -1
- data/lib/generators/matestack/core/component/USAGE +0 -16
- data/lib/generators/matestack/core/component/component_generator.rb +0 -23
- data/lib/generators/matestack/core/component/templates/app/concepts/matestack/ui/core/%file_name%/%file_name%.haml.tt +0 -5
- data/lib/generators/matestack/core/component/templates/app/concepts/matestack/ui/core/%file_name%/%file_name%.rb.tt +0 -4
- data/lib/generators/matestack/core/component/templates/docs/components/%file_name%.md.tt +0 -45
- data/lib/generators/matestack/core/component/templates/spec/usage/components/%file_name%_spec.rb +0 -31
- data/lib/generators/matestack/page/USAGE +0 -28
- data/lib/generators/matestack/page/page_generator.rb +0 -54
- data/lib/generators/matestack/page/templates/app/matestack/pages/%app_name%/%namespace%/%file_name%.rb.tt +0 -29
- data/lib/matestack/ui/core/cell.rb +0 -31
- data/lib/matestack/ui/core/component/registry.rb +0 -47
- data/lib/matestack/ui/core/components.rb +0 -271
- data/lib/matestack/ui/core/dsl.rb +0 -6
- data/lib/matestack/ui/core/engine.rb +0 -35
- data/lib/tasks/matestack/ui/core_tasks.rake +0 -4
- data/vendor/assets/javascripts/dist/manifest.json +0 -18
- data/vendor/assets/javascripts/dist/manifest.json.br +0 -0
- data/vendor/assets/javascripts/dist/manifest.json.gz +0 -0
- data/vendor/assets/javascripts/dist/matestack-ui-core.css +0 -3
- data/vendor/assets/javascripts/dist/matestack-ui-core.css.map +0 -1
- data/vendor/assets/javascripts/dist/matestack-ui-core.js +0 -17734
- data/vendor/assets/javascripts/dist/matestack-ui-core.js.map +0 -1
- data/vendor/assets/javascripts/dist/matestack-ui-core.min.css +0 -0
- data/vendor/assets/javascripts/dist/matestack-ui-core.min.js +0 -3
- data/vendor/assets/javascripts/dist/matestack-ui-core.min.js.LICENSE.txt +0 -11
- data/vendor/assets/javascripts/dist/matestack-ui-core.min.js.br +0 -0
- data/vendor/assets/javascripts/dist/matestack-ui-core.min.js.gz +0 -0
- data/vendor/assets/javascripts/dist/matestack-ui-core.min.js.map +0 -1
- data/vendor/assets/javascripts/dist/matestack-ui-core.min.js.map.br +0 -0
- data/vendor/assets/javascripts/dist/matestack-ui-core.min.js.map.gz +0 -0
- data/vendor/assets/javascripts/matestack-ui-core.js.erb +0 -2
- data/vendor/assets/stylesheets/dist +0 -1
- data/vendor/assets/stylesheets/matestack-ui-core.css.erb +0 -2
@@ -1,49 +0,0 @@
|
|
1
|
-
require_relative '../utils'
|
2
|
-
require_relative '../has_errors'
|
3
|
-
module Matestack::Ui::Core::Form::Textarea
|
4
|
-
class Base < Matestack::Ui::Core::Component::Dynamic
|
5
|
-
include Matestack::Ui::Core::Form::Utils
|
6
|
-
include Matestack::Ui::Core::Form::HasErrors
|
7
|
-
|
8
|
-
requires :key
|
9
|
-
optional :multiple, :init, for: { as: :input_for }, label: { as: :input_label }
|
10
|
-
|
11
|
-
html_attributes :autofocus, :cols, :dirname, :disabled, :form, :maxlength,
|
12
|
-
:name, :placeholder, :readonly, :required, :rows, :wrap
|
13
|
-
|
14
|
-
def setup
|
15
|
-
@component_config[:init_value] = init_value
|
16
|
-
end
|
17
|
-
|
18
|
-
def component_id
|
19
|
-
"textarea-component-for-#{attr_key}"
|
20
|
-
end
|
21
|
-
|
22
|
-
def input_key
|
23
|
-
"$parent.data[\"#{key}\"]"
|
24
|
-
end
|
25
|
-
|
26
|
-
def error_key
|
27
|
-
"$parent.errors[\"#{key}\"]"
|
28
|
-
end
|
29
|
-
|
30
|
-
def change_event
|
31
|
-
"inputChanged('#{attr_key}')"
|
32
|
-
end
|
33
|
-
|
34
|
-
def textarea_attributes
|
35
|
-
html_attributes.merge(attributes: vue_attributes)
|
36
|
-
end
|
37
|
-
|
38
|
-
def vue_attributes
|
39
|
-
(options[:attributes] || {}).merge({
|
40
|
-
'v-model': input_key,
|
41
|
-
'@change': change_event,
|
42
|
-
'v-bind:class': "{ '#{input_error_class}': #{error_key} }",
|
43
|
-
"init-value": init_value,
|
44
|
-
ref: "input.#{attr_key}",
|
45
|
-
})
|
46
|
-
end
|
47
|
-
|
48
|
-
end
|
49
|
-
end
|
@@ -1,17 +0,0 @@
|
|
1
|
-
require_relative './base'
|
2
|
-
|
3
|
-
module Matestack::Ui::Core::Form::Textarea
|
4
|
-
class Textarea < Base
|
5
|
-
|
6
|
-
vue_js_component_name "matestack-ui-core-form-textarea"
|
7
|
-
|
8
|
-
def response
|
9
|
-
div class: "matestack-ui-core-form-textarea" do
|
10
|
-
label text: input_label if input_label
|
11
|
-
textarea textarea_attributes
|
12
|
-
render_errors
|
13
|
-
end
|
14
|
-
end
|
15
|
-
|
16
|
-
end
|
17
|
-
end
|
@@ -1,47 +0,0 @@
|
|
1
|
-
module Matestack::Ui::Core::Form::Utils
|
2
|
-
|
3
|
-
def input_key
|
4
|
-
"data['#{attr_key.to_s}']"
|
5
|
-
end
|
6
|
-
|
7
|
-
def input_wrapper
|
8
|
-
case input_for
|
9
|
-
when nil
|
10
|
-
return nil
|
11
|
-
when Symbol, String
|
12
|
-
return input_for
|
13
|
-
end
|
14
|
-
if input_for.respond_to?(:model_name)
|
15
|
-
return input_for.model_name.singular
|
16
|
-
end
|
17
|
-
end
|
18
|
-
|
19
|
-
def attr_key
|
20
|
-
if input_wrapper.nil?
|
21
|
-
return "#{key.to_s}"
|
22
|
-
else
|
23
|
-
return "#{input_wrapper}.#{key.to_s}"
|
24
|
-
end
|
25
|
-
end
|
26
|
-
|
27
|
-
def init_value
|
28
|
-
return init unless init.nil?
|
29
|
-
|
30
|
-
unless input_for.nil?
|
31
|
-
value = parse_value(input_for.send key)
|
32
|
-
else
|
33
|
-
unless @included_config.nil? && @included_config[:for].nil?
|
34
|
-
if @included_config[:for].respond_to?(key)
|
35
|
-
value = parse_value(@included_config[:for].send key)
|
36
|
-
else
|
37
|
-
@included_config[:for][key] if @included_config[:for].is_a?(Hash)
|
38
|
-
end
|
39
|
-
end
|
40
|
-
end
|
41
|
-
end
|
42
|
-
|
43
|
-
def parse_value(value)
|
44
|
-
value
|
45
|
-
end
|
46
|
-
|
47
|
-
end
|
@@ -1 +0,0 @@
|
|
1
|
-
%hr{ html_attributes }
|
@@ -1 +0,0 @@
|
|
1
|
-
%img{ img_attributes }
|
@@ -1,15 +0,0 @@
|
|
1
|
-
module Matestack::Ui::Core::Img
|
2
|
-
class Img < Matestack::Ui::Core::Component::Static
|
3
|
-
html_attributes :alt, :crossorigin, :height, :ismap, :longdesc, :referrerpolicy,
|
4
|
-
:sizes, :src, :srcset, :usemap, :width
|
5
|
-
|
6
|
-
optional :path
|
7
|
-
|
8
|
-
def img_attributes
|
9
|
-
html_attributes.tap do |attributes|
|
10
|
-
attributes[:src] = ActionController::Base.helpers.asset_path(path) if path
|
11
|
-
end
|
12
|
-
end
|
13
|
-
|
14
|
-
end
|
15
|
-
end
|
@@ -1 +0,0 @@
|
|
1
|
-
%input{ html_attributes }
|
@@ -1,9 +0,0 @@
|
|
1
|
-
module Matestack::Ui::Core::Input
|
2
|
-
class Input < Matestack::Ui::Core::Component::Static
|
3
|
-
|
4
|
-
html_attributes :accept, :alt, :autocomplete, :autofocus, :checked, :dirname, :disabled, :form, :formaction,
|
5
|
-
:formenctype, :formmethod, :formnovalidate, :formtarget, :height, :list, :max, :maxlength, :min, :minlength,
|
6
|
-
:multiple, :name, :pattern, :placeholder, :readonly, :required, :size, :src, :step, :type, :value, :width
|
7
|
-
|
8
|
-
end
|
9
|
-
end
|
@@ -1,10 +0,0 @@
|
|
1
|
-
%component{dynamic_tag_attributes}
|
2
|
-
%div{loading_classes.merge(class: "matestack-isolated-component-container")}
|
3
|
-
- if loading_state_element.present?
|
4
|
-
%div{loading_classes.merge(class: "loading-state-element-wrapper")}
|
5
|
-
=loading_state_element
|
6
|
-
- unless options[:defer] || options[:init_on]
|
7
|
-
%div{class: "matestack-isolated-component-wrapper", "v-if": "isolatedTemplate == null", "v-bind:class": "{ 'loading': loading === true }"}
|
8
|
-
= render_isolated_content
|
9
|
-
%div{class: "matestack-isolated-component-wrapper", "v-if": "isolatedTemplate != null", "v-bind:class": "{ 'loading': loading === true }"}
|
10
|
-
%v-runtime-template{":template":"isolatedTemplate"}
|
@@ -1,59 +0,0 @@
|
|
1
|
-
module Matestack::Ui::Core::Isolated
|
2
|
-
class Isolated < Matestack::Ui::Core::Component::Dynamic
|
3
|
-
vue_js_component_name "matestack-ui-core-isolate"
|
4
|
-
|
5
|
-
def initialize(*args)
|
6
|
-
super
|
7
|
-
@public_options = args.map { |hash| hash&.dig(:public_options) }[0]
|
8
|
-
end
|
9
|
-
|
10
|
-
def public_options
|
11
|
-
@public_options ||= {}
|
12
|
-
end
|
13
|
-
|
14
|
-
# def params
|
15
|
-
# context[:params] || matestack_context[:params]
|
16
|
-
# end
|
17
|
-
|
18
|
-
def setup
|
19
|
-
@component_config[:component_class] = self.class.name
|
20
|
-
@component_config[:public_options] = @options[:public_options]
|
21
|
-
@component_config[:defer] = @options[:defer]
|
22
|
-
@component_config[:rerender_on] = @options[:rerender_on]
|
23
|
-
@component_config[:rerender_delay] = @options[:rerender_delay]
|
24
|
-
@component_config[:init_on] = @options[:init_on]
|
25
|
-
end
|
26
|
-
|
27
|
-
def loading_classes
|
28
|
-
{ "v-bind:class": "{ 'loading': loading === true }" }
|
29
|
-
end
|
30
|
-
|
31
|
-
# overwrite parent class render mechanism in order to make sure to only render wrapper
|
32
|
-
def render_content
|
33
|
-
show
|
34
|
-
end
|
35
|
-
|
36
|
-
# only render vuejs component wrapper on show
|
37
|
-
def show
|
38
|
-
render :isolated
|
39
|
-
end
|
40
|
-
|
41
|
-
# this method gets called when the isolate vuejs component requests isolated content
|
42
|
-
def render_isolated_content
|
43
|
-
if authorized?
|
44
|
-
render :children_wrapper do
|
45
|
-
render :children
|
46
|
-
end
|
47
|
-
end
|
48
|
-
end
|
49
|
-
|
50
|
-
def authorized?
|
51
|
-
raise "please implement the `authorized? method: isolated components have to be authorized separately"
|
52
|
-
end
|
53
|
-
|
54
|
-
def loading_state_element
|
55
|
-
nil # overwrite in subclass
|
56
|
-
end
|
57
|
-
|
58
|
-
end
|
59
|
-
end
|
@@ -1,66 +0,0 @@
|
|
1
|
-
import Vue from 'vue/dist/vue.esm'
|
2
|
-
import { turbolinksAdapterMixin } from 'vue-turbolinks';
|
3
|
-
|
4
|
-
// Import from app/concepts/matestack/ui/core:
|
5
|
-
import app from '../app/app'
|
6
|
-
import async from '../async/async'
|
7
|
-
import cable from '../cable/cable'
|
8
|
-
import pageContent from '../page/content/content'
|
9
|
-
import toggle from '../toggle/toggle'
|
10
|
-
import store from '../app/store'
|
11
|
-
import component from '../component/component'
|
12
|
-
import anonymDynamicComponent from '../component/anonym-dynamic-component'
|
13
|
-
import transition from '../transition/transition'
|
14
|
-
import action from '../action/action'
|
15
|
-
import form from '../form/form'
|
16
|
-
import formInput from '../form/input/input'
|
17
|
-
import formInputMixin from '../form/input/mixin'
|
18
|
-
import formSelect from '../form/select/select'
|
19
|
-
import formSelectMixin from '../form/select/mixin'
|
20
|
-
import formRadio from '../form/radio/radio'
|
21
|
-
import formRadioMixin from '../form/radio/mixin'
|
22
|
-
import formCheckbox from '../form/checkbox/checkbox'
|
23
|
-
import formCheckboxMixin from '../form/checkbox/mixin'
|
24
|
-
import formTextarea from '../form/textarea/textarea'
|
25
|
-
import formTextareaMixin from '../form/textarea/mixin'
|
26
|
-
import formSubmit from '../form/submit/submit'
|
27
|
-
import onclick from '../onclick/onclick'
|
28
|
-
import collectionContent from '../collection/content/content'
|
29
|
-
import collectionFilter from '../collection/filter/filter'
|
30
|
-
import collectionOrder from '../collection/order/order'
|
31
|
-
import isolate from '../isolated/isolated'
|
32
|
-
|
33
|
-
let matestackUiApp = undefined
|
34
|
-
|
35
|
-
// this event fires first and always
|
36
|
-
document.addEventListener('DOMContentLoaded', () => {
|
37
|
-
// somehow we need to inject the turbolinks mixin even
|
38
|
-
// if the turbolinks:load event will recreate the vue instance
|
39
|
-
// skipping the injection here caused errors when submitting forms or action
|
40
|
-
// if they were present on the first page, which was loaded and activated turbolinks
|
41
|
-
// the mixin does not impact the app when turbolinks is disabled
|
42
|
-
matestackUiApp = new Vue({
|
43
|
-
el: "#matestack-ui",
|
44
|
-
mixins: [turbolinksAdapterMixin],
|
45
|
-
store: store
|
46
|
-
})
|
47
|
-
})
|
48
|
-
|
49
|
-
// this event fires after DOMContentLoaded and only if turbolinks are enabled
|
50
|
-
document.addEventListener('turbolinks:load', () => {
|
51
|
-
// we need to empty the currently stored pageTemplate state variable
|
52
|
-
// otherwise the matestack page will jump back to the latest pageTemplate
|
53
|
-
// fetched during the last matestack transition as the turbolinks powered
|
54
|
-
// page transition does not write the matestack store pageTemplate state variable
|
55
|
-
store.commit('resetPageTemplate')
|
56
|
-
// we need to destroy the vue app instance
|
57
|
-
matestackUiApp.$destroy();
|
58
|
-
// and recreate it right afterwards in order to work when used with turbolinks
|
59
|
-
matestackUiApp = new Vue({
|
60
|
-
el: "#matestack-ui",
|
61
|
-
mixins: [turbolinksAdapterMixin],
|
62
|
-
store: store
|
63
|
-
})
|
64
|
-
})
|
65
|
-
|
66
|
-
export default Vue
|