diff --git a/demos/_includes/Counter.php b/demos/_includes/Counter.php index c64801ae2b..3d65543429 100644 --- a/demos/_includes/Counter.php +++ b/demos/_includes/Counter.php @@ -6,7 +6,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Form; -use Atk4\Ui\JsExpression; +use Atk4\Ui\Js\JsExpression; class Counter extends Form\Control\Line { diff --git a/demos/_includes/Demo.php b/demos/_includes/Demo.php index 7c8658d4d3..2d006a0439 100644 --- a/demos/_includes/Demo.php +++ b/demos/_includes/Demo.php @@ -6,7 +6,7 @@ use Atk4\Ui\Columns; use Atk4\Ui\Exception; -use Atk4\Ui\JsChain; +use Atk4\Ui\Js\JsChain; use Atk4\Ui\View; class Demo extends Columns diff --git a/demos/_includes/DemoLookup.php b/demos/_includes/DemoLookup.php index 3fe6b93ebe..0252aaa920 100644 --- a/demos/_includes/DemoLookup.php +++ b/demos/_includes/DemoLookup.php @@ -7,9 +7,9 @@ use Atk4\Core\Factory; use Atk4\Ui\Button; use Atk4\Ui\Form; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsModal; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsModal; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\VirtualPage; class DemoLookup extends Form\Control\Lookup diff --git a/demos/_includes/FlyersForm.php b/demos/_includes/FlyersForm.php index 65f9ba5851..64698313e1 100644 --- a/demos/_includes/FlyersForm.php +++ b/demos/_includes/FlyersForm.php @@ -7,7 +7,7 @@ use Atk4\Data\Model; use Atk4\Data\Persistence; use Atk4\Ui\Form; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; class FlyersForm extends Form { diff --git a/demos/_includes/ReloadTest.php b/demos/_includes/ReloadTest.php index 830e3eafcd..2688854f4a 100644 --- a/demos/_includes/ReloadTest.php +++ b/demos/_includes/ReloadTest.php @@ -4,7 +4,7 @@ namespace Atk4\Ui\Demos; -use Atk4\Ui\JsReload; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\Label; use Atk4\Ui\View; diff --git a/demos/_includes/ViewTester.php b/demos/_includes/ViewTester.php index fca2d069d2..7ddb00b553 100644 --- a/demos/_includes/ViewTester.php +++ b/demos/_includes/ViewTester.php @@ -4,8 +4,8 @@ namespace Atk4\Ui\Demos; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsReload; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\Label; use Atk4\Ui\View; diff --git a/demos/_unit-test/callback.php b/demos/_unit-test/callback.php index 9387908a57..d9ccb9f8c6 100644 --- a/demos/_unit-test/callback.php +++ b/demos/_unit-test/callback.php @@ -6,9 +6,9 @@ use Atk4\Ui\Button; use Atk4\Ui\Form; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsModal; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsModal; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Table; use Atk4\Ui\VirtualPage; diff --git a/demos/_unit-test/grid-rowclick.php b/demos/_unit-test/grid-rowclick.php index 13cf1561c4..6ce555a1fd 100644 --- a/demos/_unit-test/grid-rowclick.php +++ b/demos/_unit-test/grid-rowclick.php @@ -5,9 +5,9 @@ namespace Atk4\Ui\Demos; use Atk4\Ui\Grid; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsFunction; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsFunction; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Message; use Atk4\Ui\Table; use Atk4\Ui\View; diff --git a/demos/_unit-test/lookup-virtual-page.php b/demos/_unit-test/lookup-virtual-page.php index 7933f61b30..b7a6c5ac6d 100644 --- a/demos/_unit-test/lookup-virtual-page.php +++ b/demos/_unit-test/lookup-virtual-page.php @@ -6,8 +6,8 @@ use Atk4\Ui\Form; use Atk4\Ui\Grid; -use Atk4\Ui\JsModal; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsModal; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\VirtualPage; /** @var \Atk4\Ui\App $app */ diff --git a/demos/_unit-test/modal-error.php b/demos/_unit-test/modal-error.php index 0ad4107fae..2c45c4f452 100644 --- a/demos/_unit-test/modal-error.php +++ b/demos/_unit-test/modal-error.php @@ -5,7 +5,7 @@ namespace Atk4\Ui\Demos; use Atk4\Ui\Button; -use Atk4\Ui\JsExpression; +use Atk4\Ui\Js\JsExpression; use Atk4\Ui\Modal; use Atk4\Ui\UserAction\ModalExecutor; use Atk4\Ui\View; diff --git a/demos/_unit-test/post.php b/demos/_unit-test/post.php index b2c43e591d..c097c78a3e 100644 --- a/demos/_unit-test/post.php +++ b/demos/_unit-test/post.php @@ -5,7 +5,7 @@ namespace Atk4\Ui\Demos; use Atk4\Ui\Form; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; /** @var \Atk4\Ui\App $app */ require_once __DIR__ . '/../init-app.php'; diff --git a/demos/_unit-test/reload.php b/demos/_unit-test/reload.php index 3bcfa397a0..da111102a6 100644 --- a/demos/_unit-test/reload.php +++ b/demos/_unit-test/reload.php @@ -6,7 +6,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Callback; -use Atk4\Ui\JsReload; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\Loader; use Atk4\Ui\View; diff --git a/demos/_unit-test/scroll.php b/demos/_unit-test/scroll.php index 82f6477354..f74b47bc96 100644 --- a/demos/_unit-test/scroll.php +++ b/demos/_unit-test/scroll.php @@ -5,8 +5,8 @@ namespace Atk4\Ui\Demos; use Atk4\Ui\Grid; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsToast; /** @var \Atk4\Ui\App $app */ require_once __DIR__ . '/../init-app.php'; diff --git a/demos/_unit-test/sse.php b/demos/_unit-test/sse.php index f8b3cfe849..2c88e265c5 100644 --- a/demos/_unit-test/sse.php +++ b/demos/_unit-test/sse.php @@ -4,9 +4,9 @@ namespace Atk4\Ui\Demos; -use Atk4\Ui\JsExpression; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\JsSse; -use Atk4\Ui\JsToast; use Atk4\Ui\View; /** @var \Atk4\Ui\App $app */ diff --git a/demos/_unit-test/virtual-page.php b/demos/_unit-test/virtual-page.php index 93949c9f5d..b53925e148 100644 --- a/demos/_unit-test/virtual-page.php +++ b/demos/_unit-test/virtual-page.php @@ -6,7 +6,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Form; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\View; use Atk4\Ui\VirtualPage; diff --git a/demos/basic/breadcrumb.php b/demos/basic/breadcrumb.php index 38b47b5597..36c03f693e 100644 --- a/demos/basic/breadcrumb.php +++ b/demos/basic/breadcrumb.php @@ -6,7 +6,7 @@ use Atk4\Ui\Breadcrumb; use Atk4\Ui\Form; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Table; use Atk4\Ui\View; diff --git a/demos/basic/label.php b/demos/basic/label.php index 1c89b9ba80..e7959c6991 100644 --- a/demos/basic/label.php +++ b/demos/basic/label.php @@ -6,7 +6,7 @@ use Atk4\Ui\Columns; use Atk4\Ui\Header; -use Atk4\Ui\JsReload; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\Label; use Atk4\Ui\LoremIpsum; use Atk4\Ui\Menu; diff --git a/demos/basic/message.php b/demos/basic/message.php index 4a069c0d5a..baa9028b7c 100644 --- a/demos/basic/message.php +++ b/demos/basic/message.php @@ -6,8 +6,8 @@ use Atk4\Ui\Button; use Atk4\Ui\Header; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsReload; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\Message; use Atk4\Ui\View; diff --git a/demos/basic/view.php b/demos/basic/view.php index 5b02b8d71f..4f68a2f683 100644 --- a/demos/basic/view.php +++ b/demos/basic/view.php @@ -8,8 +8,8 @@ use Atk4\Ui\Columns; use Atk4\Ui\Header; use Atk4\Ui\HtmlTemplate; -use Atk4\Ui\JsModal; -use Atk4\Ui\JsReload; +use Atk4\Ui\Js\JsModal; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\Label; use Atk4\Ui\Message; use Atk4\Ui\Paginator; diff --git a/demos/collection/grid.php b/demos/collection/grid.php index 912ccb0d09..2c079ff511 100644 --- a/demos/collection/grid.php +++ b/demos/collection/grid.php @@ -7,10 +7,10 @@ use Atk4\Data\Model; use Atk4\Ui\Button; use Atk4\Ui\Grid; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsReload; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsReload; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Message; use Atk4\Ui\Table; use Atk4\Ui\UserAction\BasicExecutor; diff --git a/demos/collection/multitable.php b/demos/collection/multitable.php index 0ee0c251ef..234de18d26 100644 --- a/demos/collection/multitable.php +++ b/demos/collection/multitable.php @@ -8,9 +8,9 @@ use Atk4\Ui\Button; use Atk4\Ui\Columns; use Atk4\Ui\Header; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsModal; -use Atk4\Ui\JsReload; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsModal; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\Table; use Atk4\Ui\VirtualPage; diff --git a/demos/collection/table.php b/demos/collection/table.php index 785eeae382..8949e23685 100644 --- a/demos/collection/table.php +++ b/demos/collection/table.php @@ -6,8 +6,8 @@ use Atk4\Data\Model; use Atk4\Ui\Button; -use Atk4\Ui\JsReload; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsReload; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Table; use Atk4\Ui\View; diff --git a/demos/collection/table2.php b/demos/collection/table2.php index 92bc62b35e..79dbe6eeb3 100644 --- a/demos/collection/table2.php +++ b/demos/collection/table2.php @@ -7,8 +7,8 @@ use Atk4\Data\Model; use Atk4\Data\Persistence; use Atk4\Ui\Header; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Lister; use Atk4\Ui\Table; diff --git a/demos/data-action/actions.php b/demos/data-action/actions.php index 7b9b87aef5..9fb14a8c9e 100644 --- a/demos/data-action/actions.php +++ b/demos/data-action/actions.php @@ -8,7 +8,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Columns; use Atk4\Ui\Header; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\UserAction; use Atk4\Ui\View; diff --git a/demos/form-control/calendar.php b/demos/form-control/calendar.php index 21f6275405..daa7a9f27c 100644 --- a/demos/form-control/calendar.php +++ b/demos/form-control/calendar.php @@ -6,9 +6,9 @@ use Atk4\Ui\Form; use Atk4\Ui\GridLayout; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsFunction; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsFunction; +use Atk4\Ui\Js\JsToast; /** @var \Atk4\Ui\App $app */ require_once __DIR__ . '/../init-app.php'; diff --git a/demos/form-control/checkbox.php b/demos/form-control/checkbox.php index a5d3874e49..f7edb04ad2 100644 --- a/demos/form-control/checkbox.php +++ b/demos/form-control/checkbox.php @@ -6,7 +6,7 @@ use Atk4\Ui\Form; use Atk4\Ui\Header; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\View; /** @var \Atk4\Ui\App $app */ diff --git a/demos/form-control/form6.php b/demos/form-control/form6.php index 31e04b2490..b7042cc3fe 100644 --- a/demos/form-control/form6.php +++ b/demos/form-control/form6.php @@ -6,7 +6,7 @@ use Atk4\Ui\Columns; use Atk4\Ui\Form; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\View; /** @var \Atk4\Ui\App $app */ diff --git a/demos/form-control/input2.php b/demos/form-control/input2.php index 76d8104b70..66c80bf9c7 100644 --- a/demos/form-control/input2.php +++ b/demos/form-control/input2.php @@ -7,7 +7,7 @@ use Atk4\Ui\Form; use Atk4\Ui\Header; use Atk4\Ui\HtmlTemplate; -use Atk4\Ui\JsExpression; +use Atk4\Ui\Js\JsExpression; use Atk4\Ui\Tabs; use Atk4\Ui\View; diff --git a/demos/form-control/multiline.php b/demos/form-control/multiline.php index 0f383bba22..45eb2ce6d5 100644 --- a/demos/form-control/multiline.php +++ b/demos/form-control/multiline.php @@ -6,9 +6,9 @@ use Atk4\Ui\Form; use Atk4\Ui\Header; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsFunction; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsFunction; +use Atk4\Ui\Js\JsToast; /** @var \Atk4\Ui\App $app */ require_once __DIR__ . '/../init-app.php'; diff --git a/demos/form-control/tree-item-selector.php b/demos/form-control/tree-item-selector.php index e22bf92ed8..37c0320763 100644 --- a/demos/form-control/tree-item-selector.php +++ b/demos/form-control/tree-item-selector.php @@ -6,7 +6,7 @@ use Atk4\Ui\Form; use Atk4\Ui\Header; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Message; /** @var \Atk4\Ui\App $app */ diff --git a/demos/form-control/upload.php b/demos/form-control/upload.php index 5903733d5f..c0d34ecac2 100644 --- a/demos/form-control/upload.php +++ b/demos/form-control/upload.php @@ -5,7 +5,7 @@ namespace Atk4\Ui\Demos; use Atk4\Ui\Form; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; /** @var \Atk4\Ui\App $app */ require_once __DIR__ . '/../init-app.php'; diff --git a/demos/form/form-section.php b/demos/form/form-section.php index 49a53f5033..b6c3248631 100644 --- a/demos/form/form-section.php +++ b/demos/form/form-section.php @@ -7,7 +7,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Form; use Atk4\Ui\Header; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\View; /** @var \Atk4\Ui\App $app */ diff --git a/demos/form/form.php b/demos/form/form.php index bcfdec1e99..ffc21449a8 100644 --- a/demos/form/form.php +++ b/demos/form/form.php @@ -10,7 +10,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Form; use Atk4\Ui\Header; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Message; use Atk4\Ui\Modal; use Atk4\Ui\Tabs; diff --git a/demos/form/form2.php b/demos/form/form2.php index a5b2433527..aed9d1c204 100644 --- a/demos/form/form2.php +++ b/demos/form/form2.php @@ -8,8 +8,8 @@ use Atk4\Ui\Button; use Atk4\Ui\Form; use Atk4\Ui\Header; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Label; /** @var \Atk4\Ui\App $app */ diff --git a/demos/form/form3.php b/demos/form/form3.php index d4b580cf97..e6894249fd 100644 --- a/demos/form/form3.php +++ b/demos/form/form3.php @@ -8,7 +8,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Form; use Atk4\Ui\Header; -use Atk4\Ui\JsReload; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\View; /** @var \Atk4\Ui\App $app */ diff --git a/demos/form/form5.php b/demos/form/form5.php index 4979136aba..6dad6ad55a 100644 --- a/demos/form/form5.php +++ b/demos/form/form5.php @@ -8,7 +8,7 @@ use Atk4\Data\Persistence; use Atk4\Ui\Columns; use Atk4\Ui\Form; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\View; /** @var \Atk4\Ui\App $app */ diff --git a/demos/form/html-layout.php b/demos/form/html-layout.php index e78dfc4eba..c748759c52 100644 --- a/demos/form/html-layout.php +++ b/demos/form/html-layout.php @@ -8,7 +8,7 @@ use Atk4\Ui\Form; use Atk4\Ui\GridLayout; use Atk4\Ui\Header; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Label; use Atk4\Ui\Tabs; use Atk4\Ui\View; diff --git a/demos/interactive/jssortable.php b/demos/interactive/jssortable.php index 0f49ba68a9..153b0d80cb 100644 --- a/demos/interactive/jssortable.php +++ b/demos/interactive/jssortable.php @@ -8,8 +8,8 @@ use Atk4\Ui\Grid; use Atk4\Ui\Header; use Atk4\Ui\HtmlTemplate; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\JsSortable; -use Atk4\Ui\JsToast; use Atk4\Ui\Lister; use Atk4\Ui\View; diff --git a/demos/interactive/modal.php b/demos/interactive/modal.php index 6bc606f381..99f335697f 100644 --- a/demos/interactive/modal.php +++ b/demos/interactive/modal.php @@ -9,7 +9,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Form; use Atk4\Ui\Header; -use Atk4\Ui\JsExpression; +use Atk4\Ui\Js\JsExpression; use Atk4\Ui\LoremIpsum; use Atk4\Ui\Menu; use Atk4\Ui\Message; diff --git a/demos/interactive/popup.php b/demos/interactive/popup.php index 46f1d4727e..46e72057d0 100644 --- a/demos/interactive/popup.php +++ b/demos/interactive/popup.php @@ -9,9 +9,9 @@ use Atk4\Ui\Dropdown as UiDropdown; use Atk4\Ui\Form; use Atk4\Ui\Header; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsExpressionable; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsExpressionable; use Atk4\Ui\Label; use Atk4\Ui\Lister; use Atk4\Ui\Menu; diff --git a/demos/interactive/scroll-grid-container.php b/demos/interactive/scroll-grid-container.php index 7652d68234..1f6754d0dd 100644 --- a/demos/interactive/scroll-grid-container.php +++ b/demos/interactive/scroll-grid-container.php @@ -10,7 +10,7 @@ use Atk4\Ui\Crud; use Atk4\Ui\Grid; use Atk4\Ui\Header; -use Atk4\Ui\Jquery; +use Atk4\Ui\Js\Jquery; use Atk4\Ui\View; /** @var \Atk4\Ui\App $app */ diff --git a/demos/interactive/sse.php b/demos/interactive/sse.php index f937d663b4..820f84d7b1 100644 --- a/demos/interactive/sse.php +++ b/demos/interactive/sse.php @@ -6,7 +6,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Header; -use Atk4\Ui\Jquery; +use Atk4\Ui\Js\Jquery; use Atk4\Ui\JsSse; use Atk4\Ui\ProgressBar; use Atk4\Ui\View; diff --git a/demos/interactive/toast.php b/demos/interactive/toast.php index 7728a95775..fce1245650 100644 --- a/demos/interactive/toast.php +++ b/demos/interactive/toast.php @@ -6,7 +6,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Header; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; /** @var \Atk4\Ui\App $app */ require_once __DIR__ . '/../init-app.php'; diff --git a/demos/interactive/virtual.php b/demos/interactive/virtual.php index 72e8be6771..803b65ef66 100644 --- a/demos/interactive/virtual.php +++ b/demos/interactive/virtual.php @@ -6,7 +6,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Header; -use Atk4\Ui\JsModal; +use Atk4\Ui\Js\JsModal; use Atk4\Ui\LoremIpsum; use Atk4\Ui\Message; use Atk4\Ui\Modal; diff --git a/demos/javascript/js.php b/demos/javascript/js.php index 3a5468365d..8f0f473848 100644 --- a/demos/javascript/js.php +++ b/demos/javascript/js.php @@ -7,8 +7,8 @@ use Atk4\Ui\Button; use Atk4\Ui\Exception; use Atk4\Ui\Header; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsExpression; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; use Atk4\Ui\Label; /** @var \Atk4\Ui\App $app */ diff --git a/demos/javascript/reloading.php b/demos/javascript/reloading.php index a465540303..bdeb8919a7 100644 --- a/demos/javascript/reloading.php +++ b/demos/javascript/reloading.php @@ -7,8 +7,8 @@ use Atk4\Ui\Button; use Atk4\Ui\Form; use Atk4\Ui\Header; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsReload; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\View; /** @var \Atk4\Ui\App $app */ diff --git a/demos/javascript/vue-component.php b/demos/javascript/vue-component.php index f7e627ba51..d25d407823 100644 --- a/demos/javascript/vue-component.php +++ b/demos/javascript/vue-component.php @@ -7,7 +7,7 @@ use Atk4\Ui\Button; use Atk4\Ui\Header; use Atk4\Ui\HtmlTemplate; -use Atk4\Ui\JsExpression; +use Atk4\Ui\Js\JsExpression; use Atk4\Ui\Lister; use Atk4\Ui\Message; use Atk4\Ui\View; diff --git a/demos/layout/layout-panel.php b/demos/layout/layout-panel.php index b266563f2a..a997b2b9c2 100644 --- a/demos/layout/layout-panel.php +++ b/demos/layout/layout-panel.php @@ -9,8 +9,8 @@ use Atk4\Ui\Form; use Atk4\Ui\Header; use Atk4\Ui\Icon; -use Atk4\Ui\JsReload; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsReload; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Message; use Atk4\Ui\Panel; use Atk4\Ui\Text; diff --git a/demos/others/recursive.php b/demos/others/recursive.php index 4079e32be4..40b69d978b 100644 --- a/demos/others/recursive.php +++ b/demos/others/recursive.php @@ -6,8 +6,8 @@ use Atk4\Ui\Button; use Atk4\Ui\Header; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsReload; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\View; /** @var \Atk4\Ui\App $app */ diff --git a/demos/others/sticky2.php b/demos/others/sticky2.php index 1bf60750da..4501a8aae8 100644 --- a/demos/others/sticky2.php +++ b/demos/others/sticky2.php @@ -7,8 +7,8 @@ use Atk4\Ui\Button; use Atk4\Ui\Console; use Atk4\Ui\Header; -use Atk4\Ui\JsReload; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsReload; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Label; use Atk4\Ui\Loader; use Atk4\Ui\Table; diff --git a/demos/tutorial/intro.php b/demos/tutorial/intro.php index 7549775b27..c6621b0e5d 100644 --- a/demos/tutorial/intro.php +++ b/demos/tutorial/intro.php @@ -10,7 +10,7 @@ use Atk4\Ui\Card; use Atk4\Ui\Form; use Atk4\Ui\Header; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Message; use Atk4\Ui\Paginator; use Atk4\Ui\Text; diff --git a/docs/app.rst b/docs/app.rst index c684748489..56c5032286 100644 --- a/docs/app.rst +++ b/docs/app.rst @@ -424,7 +424,7 @@ Populating the left menu object is simply a matter of adding the right menu item This is the top menu of the admin layout. You can add other item to the top menu using:: Button::addTo($layout->menu->addItem(), ['View Source', 'class.teal' => true, 'icon' => 'github']) - ->setAttr('target', '_blank')->on('click', new \Atk4\Ui\JsExpression('document.location = [];', [$url . $f])); + ->setAttr('target', '_blank')->on('click', new \Atk4\Ui\Js\JsExpression('document.location = [];', [$url . $f])); .. php:attr:: menuRight diff --git a/docs/autocomplete.rst b/docs/autocomplete.rst index e1ed80739e..99c0c12ee6 100644 --- a/docs/autocomplete.rst +++ b/docs/autocomplete.rst @@ -51,7 +51,7 @@ You can do much more with AutoComplete form control by passing dropdown settings 'settings' => [ 'allowReselection' => true, 'selectOnKeydown' => false, - 'onChange' => new \Atk4\Ui\JsExpression('function (value, t, c) { + 'onChange' => new \Atk4\Ui\Js\JsExpression('function (value, t, c) { if ($(this).data(\'value\') !== value) { $(this).parents(\'.form\').form(\'submit\'); $(this).data(\'value\', value); diff --git a/docs/callbacks.rst b/docs/callbacks.rst index c5fbbbac29..a6dd8cb835 100644 --- a/docs/callbacks.rst +++ b/docs/callbacks.rst @@ -168,7 +168,7 @@ Here is example of JsReload:: $view = \Atk4\Ui\View::addTo($app, ['ui' => 'tertiary green inverted segment']); $button = \Atk4\Ui\Button::addTo($app, ['Reload Lorem']); - $button->on('click', new \Atk4\Ui\JsReload($view)); + $button->on('click', new \Atk4\Ui\Js\JsReload($view)); \Atk4\Ui\LoremIpsum::addTo($view); @@ -277,9 +277,9 @@ will send browser screen width back to the callback:: $label = \Atk4\Ui\Label::addTo($app); $cb = \Atk4\Ui\JsCallback::addTo($label); - $cb->set(function (\Atk4\Ui\Jquery $j, $arg1) { + $cb->set(function (\Atk4\Ui\Js\Jquery $j, $arg1) { return 'width is ' . $arg1; - }, [new \Atk4\Ui\JsExpression( '$(window).width()' )]); + }, [new \Atk4\Ui\Js\JsExpression( '$(window).width()' )]); $label->detail = $cb->getUrl(); $label->on('click', $cb); @@ -292,7 +292,7 @@ also supports argument passing:: $label->on('click', function (Jquery $j, $arg1) { return 'width is ' . $arg1; - }, ['confirm' => 'sure?', 'args' => [new \Atk4\Ui\JsExpression( '$(window).width()' )]]); + }, ['confirm' => 'sure?', 'args' => [new \Atk4\Ui\Js\JsExpression( '$(window).width()' )]]); If you do not need to specify confirm, you can actually pass arguments in a key-less array too:: @@ -300,7 +300,7 @@ If you do not need to specify confirm, you can actually pass arguments in a key- $label->on('click', function (Jquery $j, $arg1) { return 'width is ' . $arg1; - }, [new \Atk4\Ui\JsExpression( '$(window).width()' )]); + }, [new \Atk4\Ui\Js\JsExpression( '$(window).width()' )]); Refering to event origin diff --git a/docs/console.rst b/docs/console.rst index 5ecec24fb3..fe3d647021 100644 --- a/docs/console.rst +++ b/docs/console.rst @@ -31,7 +31,7 @@ After adding a console to your :ref:`render_tree`, you just need to set a call-b $console->output('hello'); echo 'world'; // also will be redirected to console sleep(2); - $console->send(new \Atk4\Ui\JsExpression('alert([])', ['The wait is over'])); + $console->send(new \Atk4\Ui\Js\JsExpression('alert([])', ['The wait is over'])); }); Console uses :ref:`sse` which works pretty much out-of-the-box with the modern browsers and unlike websockets diff --git a/docs/crud.rst b/docs/crud.rst index 6f07d35888..4e00340604 100644 --- a/docs/crud.rst +++ b/docs/crud.rst @@ -101,7 +101,7 @@ specify your own form behavior using a callback for action:: // callback for both model action edit and add. $g->onFormAddEdit(function (Form $form, ModalExecutor $ex) { $form->onSubmit(function (Form $form) use ($ex) { - return [$ex->hide(), new \Atk4\Ui\JsToast('Submit all right! This demo does not saved data.')]; + return [$ex->hide(), new \Atk4\Ui\Js\JsToast('Submit all right! This demo does not saved data.')]; }); }); diff --git a/docs/dataexecutor.rst b/docs/dataexecutor.rst index f137547e09..f8793057ba 100644 --- a/docs/dataexecutor.rst +++ b/docs/dataexecutor.rst @@ -20,7 +20,7 @@ Executor Interface .. php:namespace:: Atk4\Ui\UserAction -All executors must implement the Executor or JsExecutor interface. +All executors must implement the ExecutorInterface or JsExecutorInterface interface. .. php:interface:: ExecutorInterface .. php:interface:: JsExecutorInterface diff --git a/docs/fileupload.rst b/docs/fileupload.rst index 453c5f441d..9ad637ac6e 100644 --- a/docs/fileupload.rst +++ b/docs/fileupload.rst @@ -86,7 +86,7 @@ Example showing the onUpload callback on the UploadImage field:: $img->setFileId('123456'); // can also return a notifier. - return new \Atk4\Ui\JsToast([ + return new \Atk4\Ui\Js\JsToast([ 'message' => 'File is uploaded!', 'class' => 'success', ]); @@ -120,7 +120,7 @@ Example showing the onDelete callback on the UploadImage field:: // reset thumbanil $img->clearThumbnail('./images/default.png'); - return new \Atk4\Ui\JsToast([ + return new \Atk4\Ui\Js\JsToast([ 'message' => $fileId . ' has been removed!', 'class' => 'success', ]); diff --git a/docs/form-control.rst b/docs/form-control.rst index b4207778dd..4801c45e34 100644 --- a/docs/form-control.rst +++ b/docs/form-control.rst @@ -35,7 +35,7 @@ You can set default value and interact with a form control using JavaScript:: $button = \Atk4\Ui\Button::addTo($app, ['check value']); - $button->on('click', new \Atk4\Ui\JsExpression('alert(\'control value is: \' + [])', [$control->jsInput()->val()])); + $button->on('click', new \Atk4\Ui\Js\JsExpression('alert(\'control value is: \' + [])', [$control->jsInput()->val()])); When used stand-alone, Form\Controls will produce a basic HTML (I have omitted id=):: @@ -305,7 +305,7 @@ $expression argument can be string, JsExpression, array of JsExpressions or even // callback $f2 = $form->addControl('f2'); $f2->onChange(function () { - return new \Atk4\Ui\JsExpression('console.log(\'f2 changed\')'); + return new \Atk4\Ui\Js\JsExpression('console.log(\'f2 changed\')'); }); // Calendar form control - wraps in function call with arguments date, text and mode diff --git a/docs/grid.rst b/docs/grid.rst index a3f7026961..d296cff1c8 100644 --- a/docs/grid.rst +++ b/docs/grid.rst @@ -25,7 +25,7 @@ To make your grid look nicer, you might want to add some buttons and enable quic $grid->setModel(new Country($db)); $grid->addQuickSearch(); - $grid->menu->addItem('Reload Grid', new \Atk4\Ui\JsReload($grid)); + $grid->menu->addItem('Reload Grid', new \Atk4\Ui\Js\JsReload($grid)); Adding Menu Items ================= @@ -154,7 +154,7 @@ additionally place this column before any other column inside a grid. You can us method to reference value of selected checkboxes inside any :ref:`js_action`:: $sel = $grid->addSelection(); - $grid->menu->addItem('show selection')->on('click', new \Atk4\Ui\JsExpression( + $grid->menu->addItem('show selection')->on('click', new \Atk4\Ui\Js\JsExpression( 'alert(\'Selected: \' + [])', [$sel->jsChecked()] )); diff --git a/docs/js.rst b/docs/js.rst index 5e7cc26385..dae3d2c7b0 100644 --- a/docs/js.rst +++ b/docs/js.rst @@ -450,7 +450,7 @@ To accomplish that, use a :ref:`virtualpage`:: \Atk4\Ui\LoremIpsum::addTo($vp, ['size' => 2]); \Atk4\Ui\Button::addTo($app, ['Dynamic Modal']) - ->on('click', new \Atk4\Ui\JsModal('My Popup Title', $vp->getUrl('cut'))); + ->on('click', new \Atk4\Ui\Js\JsModal('My Popup Title', $vp->getUrl('cut'))); Note that this element is always destroyed as opposed to :php:class:`Modal`, where it is only hidden. @@ -482,7 +482,7 @@ other view:: $form->onSubmit(function (Form $form) use ($table) { $form->model->save(); - return new \Atk4\Ui\JsReload($table); + return new \Atk4\Ui\Js\JsReload($table); }); $t->setModel($m_book); @@ -519,7 +519,7 @@ The following will **not** work:: $table->setModel(clone $model)); $button = \Atk4\Ui\Button::addTo($app, ['Add Item', 'icon' => 'plus']); - $button->on('click', new \Atk4\Ui\JsModal('JSModal Title', $vp)); + $button->on('click', new \Atk4\Ui\Js\JsModal('JSModal Title', $vp)); $form->onSubmit(function (Form $form) use ($table) { $form->model->save(); @@ -544,7 +544,7 @@ Table needs to be first! The following works:: $form->setModel(clone $model); $button = \Atk4\Ui\Button::addTo($app, ['Add Item', 'icon' => 'plus']); - $button->on('click', new \Atk4\Ui\JsModal('JSModal Title', $vp)); + $button->on('click', new \Atk4\Ui\Js\JsModal('JSModal Title', $vp)); $form->onSubmit(function (Form $form) use ($table) { $form->model->save(); @@ -578,7 +578,7 @@ VirtualPage content is rendered. To force yourself to put things in order you ca }); $button = \Atk4\Ui\Button::addTo($app, ['Add Item', 'icon' => 'plus']); - $button->on('click', new \Atk4\Ui\JsModal('JSModal Title', $vp)); + $button->on('click', new \Atk4\Ui\Js\JsModal('JSModal Title', $vp)); Note that in no case you will be able to render the button *above* the table (because the button needs a reference to `$vp` which references `$table` for reload), so `$button` must be last. diff --git a/docs/quickstart.rst b/docs/quickstart.rst index 385abe9b9a..43a346a12c 100644 --- a/docs/quickstart.rst +++ b/docs/quickstart.rst @@ -197,7 +197,7 @@ Form and Crud Components Next we need to add Components that are capable of manipulating the data:: $col = \Atk4\Ui\Columns::addTo($app, ['divided']); - $col_reload = new \Atk4\Ui\JsReload($col); + $col_reload = new \Atk4\Ui\Js\JsReload($col); $form = \Atk4\Ui\Form::addTo($col->addColumn()); $form->setModel(new ToDoItem($s)); @@ -252,7 +252,7 @@ another. In our example replace right column (label 17) with the following code: $grid->setModel(new ToDoItem($s)); $grid->menu->addItem('Complete Selected', - new \Atk4\Ui\JsReload($grid->table, [ + new \Atk4\Ui\Js\JsReload($grid->table, [ 'delete' => $grid->addSelection()->jsChecked(), ]) ); diff --git a/docs/tree-item-selector.rst b/docs/tree-item-selector.rst index 9a31f64585..e903d7eef3 100644 --- a/docs/tree-item-selector.rst +++ b/docs/tree-item-selector.rst @@ -92,7 +92,7 @@ It is possible to run a callback function every time an item is select on the li set by the user.:: $control->onItem(function (array $value) { - return new \Atk4\Ui\JsToast($this->getApp()->encodeJson($value)); + return new \Atk4\Ui\Js\JsToast($this->getApp()->encodeJson($value)); }); Note diff --git a/docs/view.rst b/docs/view.rst index 4b485b1df2..ce2e77a948 100644 --- a/docs/view.rst +++ b/docs/view.rst @@ -460,7 +460,7 @@ which will respond with JavaScript Action for reloading the view:: $b1->on('click', $b2->jsReload()); // Previously: - // $b1->on('click', new \Atk4\Ui\JsReload($b2)); + // $b1->on('click', new \Atk4\Ui\Js\JsReload($b2)); diff --git a/docs/virtualpage.rst b/docs/virtualpage.rst index 07ce8467f4..c9f900fb92 100644 --- a/docs/virtualpage.rst +++ b/docs/virtualpage.rst @@ -231,7 +231,7 @@ Next example will display DataTable, but will allow you to replace data with a f $form->addControl('year'); $form->onSubmit(function (Form $form) use ($p) { - return new \Atk4\Ui\JsReload($p, ['year' => $form->model->get('year')]); + return new \Atk4\Ui\Js\JsReload($p, ['year' => $form->model->get('year')]); }); }); diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 54e3287590..03b1700ef4 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -23,13 +23,13 @@ parameters: # for level = 2 - path: 'demos/_includes/Demo.php' - message: '~^Call to an undefined method Atk4\\Ui\\JsChain::initHighlighting\(\)\.$~' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\JsChain::initHighlighting\(\)\.$~' - path: 'demos/collection/grid.php' message: '~^Call to an undefined method Atk4\\Ui\\AbstractView&Atk4\\Ui\\UserAction\\ExecutorInterface::onHook\(\)\.$~' - path: 'demos/collection/multitable.php' - message: '~^Call to an undefined method Atk4\\Ui\\Jquery::remove\(\)\.$~' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\Jquery::remove\(\)\.$~' - path: 'demos/collection/tablefilter.php' message: '~^Call to an undefined method Atk4\\Ui\\Demos\\Country::expr\(\)\.$~' @@ -143,22 +143,22 @@ parameters: message: '~^Call to an undefined method Atk4\\Ui\\AbstractView::addButton\(\)\.$~' - path: 'src/Form.php' - message: '~^Call to an undefined method Atk4\\Ui\\JsChain::preventFormLeave\(\)\.$~' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\JsChain::preventFormLeave\(\)\.$~' - path: 'src/Form/Control/Calendar.php' - message: '~^Access to an undefined property Atk4\\Ui\\Jquery::\$_flatpickr\.$~' + message: '~^Access to an undefined property Atk4\\Ui\\Js\\Jquery::\$_flatpickr\.$~' - path: 'src/Form/Control/Checkbox.php' - message: '~^Access to an undefined property Atk4\\Ui\\Jquery::\$checked\.$~' + message: '~^Access to an undefined property Atk4\\Ui\\Js\\Jquery::\$checked\.$~' - path: 'src/Form/Control/Multiline.php' message: '~^Call to an undefined method Atk4\\Data\\Model::expr\(\)\.$~' - - path: 'src/JsVueService.php' - message: '~^Call to an undefined method Atk4\\Ui\\JsChain::createAtkVue\(\)\.$~' + path: 'src/Js/JsVueService.php' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\JsChain::createAtkVue\(\)\.$~' - - path: 'src/JsVueService.php' - message: '~^Call to an undefined method Atk4\\Ui\\JsChain::createVue\(\)\.$~' + path: 'src/Js/JsVueService.php' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\JsChain::createVue\(\)\.$~' - path: 'src/Menu.php' message: '~^Call to an undefined method Atk4\\Ui\\AbstractView::setElement\(\)\.$~' @@ -167,13 +167,13 @@ parameters: message: '~^Call to an undefined method Atk4\\Ui\\AbstractView::addClass\(\)\.$~' - path: 'src/Panel/Right.php' - message: '~^Call to an undefined method Atk4\\Ui\\JsChain::openPanel\(\)\.$~' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\JsChain::openPanel\(\)\.$~' - path: 'src/Panel/Right.php' - message: '~^Call to an undefined method Atk4\\Ui\\JsChain::reloadPanel\(\)\.$~' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\JsChain::reloadPanel\(\)\.$~' - path: 'src/Panel/Right.php' - message: '~^Call to an undefined method Atk4\\Ui\\JsChain::closePanel\(\)\.$~' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\JsChain::closePanel\(\)\.$~' - path: 'src/Panel/Right.php' message: '~^Call to an undefined method Atk4\\Ui\\AbstractView::addButtonAction\(\)\.$~' @@ -185,7 +185,7 @@ parameters: message: '~^Call to an undefined method Atk4\\Ui\\Panel\\LoadableContent::getClearSelector\(\)\.$~' - path: 'src/Panel/Right.php' - message: '~^Call to an undefined method Atk4\\Ui\\JsChain::addPanel\(\)\.$~' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\JsChain::addPanel\(\)\.$~' - path: 'src/SessionTrait.php' count: 4 @@ -222,13 +222,13 @@ parameters: message: '~^Call to an undefined method Atk4\\Ui\\AbstractView::setElement\(\)\.$~' - path: 'src/View.php' - message: '~^Call to an undefined method Atk4\\Ui\\JsChain::emit\(\)\.$~' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\JsChain::emit\(\)\.$~' - path: 'src/View.php' - message: '~^Call to an undefined method Atk4\\Ui\\JsChain::clearData\(\)\.$~' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\JsChain::clearData\(\)\.$~' - path: 'src/View.php' - message: '~^Call to an undefined method Atk4\\Ui\\JsChain::addJsonData\(\)\.$~' + message: '~^Call to an undefined method Atk4\\Ui\\Js\\JsChain::addJsonData\(\)\.$~' - path: 'src/View.php' message: '~^Call to an undefined method Atk4\\Ui\\App::getViewJS\(\)\.$~' diff --git a/src/Accordion.php b/src/Accordion.php index 644c6dc616..b402a282c1 100644 --- a/src/Accordion.php +++ b/src/Accordion.php @@ -4,6 +4,8 @@ namespace Atk4\Ui; +use Atk4\Ui\Js\JsChain; + /** * Accordion is a View holding accordion sections. * diff --git a/src/App.php b/src/App.php index 562623fdb2..37690db54c 100644 --- a/src/App.php +++ b/src/App.php @@ -17,6 +17,7 @@ use Atk4\Ui\Exception\ExitApplicationError; use Atk4\Ui\Exception\LateOutputError; use Atk4\Ui\Exception\UnhandledCallbackExceptionError; +use Atk4\Ui\Js\JsExpression; use Atk4\Ui\Persistence\Ui as UiPersistence; use Atk4\Ui\UserAction\ExecutorFactory; use Psr\Log\LoggerInterface; diff --git a/src/Card.php b/src/Card.php index 53fbbc28bf..e51cf8c602 100644 --- a/src/Card.php +++ b/src/Card.php @@ -6,6 +6,7 @@ use Atk4\Core\Factory; use Atk4\Data\Model; +use Atk4\Ui\Js\Jquery; use Atk4\Ui\UserAction\ExecutorFactory; /** diff --git a/src/CardDeck.php b/src/CardDeck.php index 737e0dd51f..8d421af52e 100644 --- a/src/CardDeck.php +++ b/src/CardDeck.php @@ -6,6 +6,9 @@ use Atk4\Core\Factory; use Atk4\Data\Model; +use Atk4\Ui\Js\JsExpressionable; +use Atk4\Ui\Js\JsFunction; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\UserAction\ExecutorFactory; use Atk4\Ui\UserAction\ExecutorInterface; diff --git a/src/Console.php b/src/Console.php index fca23cf57e..92cf15f550 100644 --- a/src/Console.php +++ b/src/Console.php @@ -6,6 +6,7 @@ use Atk4\Core\DebugTrait; use Atk4\Core\TraitUtil; +use Atk4\Ui\Js\JsExpressionable; /** * Console is a black square component resembling terminal window. It can be programmed diff --git a/src/Crud.php b/src/Crud.php index 44faf767e4..071242101d 100644 --- a/src/Crud.php +++ b/src/Crud.php @@ -6,6 +6,11 @@ use Atk4\Core\Factory; use Atk4\Data\Model; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsExpressionable; +use Atk4\Ui\Js\JsFunction; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\UserAction\ExecutorFactory; use Atk4\Ui\UserAction\ExecutorInterface; diff --git a/src/Dropdown.php b/src/Dropdown.php index 40b9753ef1..c13e479f7f 100644 --- a/src/Dropdown.php +++ b/src/Dropdown.php @@ -4,6 +4,10 @@ namespace Atk4\Ui; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsFunction; + class Dropdown extends Lister { public $ui = 'dropdown'; diff --git a/src/Form.php b/src/Form.php index 67f642045f..2e43b51e99 100644 --- a/src/Form.php +++ b/src/Form.php @@ -11,6 +11,10 @@ use Atk4\Data\Reference\ContainsMany; use Atk4\Data\ValidationException; use Atk4\Ui\Form\Control; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsChain; +use Atk4\Ui\Js\JsConditionalForm; +use Atk4\Ui\Js\JsExpression; class Form extends View { diff --git a/src/Form/Control.php b/src/Form/Control.php index 45ba0b0d19..28b07a029a 100644 --- a/src/Form/Control.php +++ b/src/Form/Control.php @@ -9,9 +9,9 @@ use Atk4\Data\Model\EntityFieldPair; use Atk4\Ui\Exception; use Atk4\Ui\Form; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsExpressionable; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsExpressionable; use Atk4\Ui\View; /** diff --git a/src/Form/Control/Calendar.php b/src/Form/Control/Calendar.php index a39d073639..68f7a6cebb 100644 --- a/src/Form/Control/Calendar.php +++ b/src/Form/Control/Calendar.php @@ -4,9 +4,9 @@ namespace Atk4\Ui\Form\Control; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsFunction; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsFunction; /** * Date/Time picker attached to a form control. diff --git a/src/Form/Control/Checkbox.php b/src/Form/Control/Checkbox.php index 4cd537624f..e8b0e07621 100644 --- a/src/Form/Control/Checkbox.php +++ b/src/Form/Control/Checkbox.php @@ -6,8 +6,8 @@ use Atk4\Ui\Exception; use Atk4\Ui\Form; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsExpressionable; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpressionable; class Checkbox extends Form\Control { diff --git a/src/Form/Control/Dropdown.php b/src/Form/Control/Dropdown.php index d0cf1366fb..4516201677 100644 --- a/src/Form/Control/Dropdown.php +++ b/src/Form/Control/Dropdown.php @@ -4,9 +4,9 @@ namespace Atk4\Ui\Form\Control; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsExpressionable; -use Atk4\Ui\JsFunction; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsExpressionable; +use Atk4\Ui\Js\JsFunction; class Dropdown extends Input { diff --git a/src/Form/Control/DropdownCascade.php b/src/Form/Control/DropdownCascade.php index 81ecdc121f..6db5295b02 100644 --- a/src/Form/Control/DropdownCascade.php +++ b/src/Form/Control/DropdownCascade.php @@ -6,7 +6,7 @@ use Atk4\Data\Model; use Atk4\Ui\Form; -use Atk4\Ui\Jquery; +use Atk4\Ui\Js\Jquery; /** * Dropdown form control that will based it's list value diff --git a/src/Form/Control/Lookup.php b/src/Form/Control/Lookup.php index 8b83c236af..5d560eed38 100644 --- a/src/Form/Control/Lookup.php +++ b/src/Form/Control/Lookup.php @@ -12,10 +12,10 @@ use Atk4\Ui\Callback; use Atk4\Ui\Exception; use Atk4\Ui\Form; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsFunction; -use Atk4\Ui\JsModal; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsFunction; +use Atk4\Ui\Js\JsModal; use Atk4\Ui\VirtualPage; class Lookup extends Input diff --git a/src/Form/Control/Multiline.php b/src/Form/Control/Multiline.php index 1bed205000..977d4b13a9 100644 --- a/src/Form/Control/Multiline.php +++ b/src/Form/Control/Multiline.php @@ -14,8 +14,8 @@ use Atk4\Ui\Exception; use Atk4\Ui\Form; use Atk4\Ui\HtmlTemplate; +use Atk4\Ui\Js\JsFunction; use Atk4\Ui\JsCallback; -use Atk4\Ui\JsFunction; use Atk4\Ui\View; /** diff --git a/src/Form/Control/Radio.php b/src/Form/Control/Radio.php index 6d129f8472..0af5c1e924 100644 --- a/src/Form/Control/Radio.php +++ b/src/Form/Control/Radio.php @@ -5,7 +5,7 @@ namespace Atk4\Ui\Form\Control; use Atk4\Ui\Form; -use Atk4\Ui\JsExpression; +use Atk4\Ui\Js\JsExpression; use Atk4\Ui\Lister; class Radio extends Form\Control diff --git a/src/Form/Control/TreeItemSelector.php b/src/Form/Control/TreeItemSelector.php index 63c144ee18..df900c0d36 100644 --- a/src/Form/Control/TreeItemSelector.php +++ b/src/Form/Control/TreeItemSelector.php @@ -6,7 +6,7 @@ use Atk4\Ui\Form; use Atk4\Ui\HtmlTemplate; -use Atk4\Ui\Jquery; +use Atk4\Ui\Js\Jquery; use Atk4\Ui\JsCallback; use Atk4\Ui\View; diff --git a/src/Form/Control/Upload.php b/src/Form/Control/Upload.php index c595580397..779d4ad044 100644 --- a/src/Form/Control/Upload.php +++ b/src/Form/Control/Upload.php @@ -6,8 +6,8 @@ use Atk4\Ui\Button; use Atk4\Ui\Exception; +use Atk4\Ui\Js\JsExpressionable; use Atk4\Ui\JsCallback; -use Atk4\Ui\JsExpressionable; class Upload extends Input { diff --git a/src/Grid.php b/src/Grid.php index 0b17a41331..94f730d331 100644 --- a/src/Grid.php +++ b/src/Grid.php @@ -8,6 +8,10 @@ use Atk4\Core\HookTrait; use Atk4\Data\Field; use Atk4\Data\Model; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsExpressionable; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\UserAction\ConfirmationExecutor; use Atk4\Ui\UserAction\ExecutorFactory; use Atk4\Ui\UserAction\ExecutorInterface; diff --git a/src/ItemsPerPageSelector.php b/src/ItemsPerPageSelector.php index aaf7caa65a..44f4814682 100644 --- a/src/ItemsPerPageSelector.php +++ b/src/ItemsPerPageSelector.php @@ -4,6 +4,8 @@ namespace Atk4\Ui; +use Atk4\Ui\Js\JsExpression; + /** * Implement an item per page length selector. * Set as a dropdown menu which contains the number of items per page need. diff --git a/src/Jquery.php b/src/Js/Jquery.php similarity index 99% rename from src/Jquery.php rename to src/Js/Jquery.php index 882d88a2e3..9661a1ff8f 100644 --- a/src/Jquery.php +++ b/src/Js/Jquery.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Atk4\Ui; +namespace Atk4\Ui\Js; /** * Implements mapper for jQuery library. Following mappings are just to keep phpstan/PhpStorm happy. diff --git a/src/JsChain.php b/src/Js/JsChain.php similarity index 97% rename from src/JsChain.php rename to src/Js/JsChain.php index e0d1828514..31e4f1d595 100644 --- a/src/JsChain.php +++ b/src/Js/JsChain.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Atk4\Ui; +namespace Atk4\Ui\Js; /** * Implements a transparent mapper that will actually translate into JavaScript code. Used @@ -42,7 +42,7 @@ class JsChain extends JsExpression * * will be stored in $chain as * - * [ ['foo'], ['bar', [1]], 'baz', ['test', ['abc => 123]] ] + * [['foo'], ['bar', [1]], 'baz', ['test', ['abc => 123]]] * * will map into: * diff --git a/src/JsConditionalForm.php b/src/Js/JsConditionalForm.php similarity index 96% rename from src/JsConditionalForm.php rename to src/Js/JsConditionalForm.php index 3e0910c7eb..ed5c86c0a1 100644 --- a/src/JsConditionalForm.php +++ b/src/Js/JsConditionalForm.php @@ -2,9 +2,10 @@ declare(strict_types=1); -namespace Atk4\Ui; +namespace Atk4\Ui\Js; use Atk4\Core\DiContainerTrait; +use Atk4\Ui\Form; /** * Implements conditions for displaying fields on form. diff --git a/src/JsExpression.php b/src/Js/JsExpression.php similarity index 98% rename from src/JsExpression.php rename to src/Js/JsExpression.php index 7786a70116..c4ff4f9e89 100644 --- a/src/JsExpression.php +++ b/src/Js/JsExpression.php @@ -2,10 +2,11 @@ declare(strict_types=1); -namespace Atk4\Ui; +namespace Atk4\Ui\Js; use Atk4\Core\DiContainerTrait; use Atk4\Data\Persistence; +use Atk4\Ui\Exception; /** * Implements a class that can be mapped into arbitrary JavaScript expression. diff --git a/src/JsExpressionable.php b/src/Js/JsExpressionable.php similarity index 89% rename from src/JsExpressionable.php rename to src/Js/JsExpressionable.php index 3528262f07..0496c09f9d 100644 --- a/src/JsExpressionable.php +++ b/src/Js/JsExpressionable.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Atk4\Ui; +namespace Atk4\Ui\Js; /** * Implements a class that can be mapped into arbitrary JavaScript expression. diff --git a/src/JsFunction.php b/src/Js/JsFunction.php similarity index 98% rename from src/JsFunction.php rename to src/Js/JsFunction.php index 461c66c890..ce4c1aedf5 100644 --- a/src/JsFunction.php +++ b/src/Js/JsFunction.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Atk4\Ui; +namespace Atk4\Ui\Js; use Atk4\Core\WarnDynamicPropertyTrait; diff --git a/src/JsModal.php b/src/Js/JsModal.php similarity index 96% rename from src/JsModal.php rename to src/Js/JsModal.php index 45f737264f..8f7c7d510a 100644 --- a/src/JsModal.php +++ b/src/Js/JsModal.php @@ -2,7 +2,9 @@ declare(strict_types=1); -namespace Atk4\Ui; +namespace Atk4\Ui\Js; + +use Atk4\Ui\VirtualPage; /** * This class generates action, that will be able to loop-back to the callback method. @@ -27,7 +29,7 @@ public function __construct($title, $url, array $args = [], string $dataType = ' } /** - * Set additionnal option for this JsModal. + * Set additional option for this JsModal. * * Valuable option are headerCss and label: * 'headerCss' -> customize css class name for the header. diff --git a/src/JsReload.php b/src/Js/JsReload.php similarity index 97% rename from src/JsReload.php rename to src/Js/JsReload.php index 0d2eca5f2e..fb8ec070f3 100644 --- a/src/JsReload.php +++ b/src/Js/JsReload.php @@ -2,9 +2,10 @@ declare(strict_types=1); -namespace Atk4\Ui; +namespace Atk4\Ui\Js; use Atk4\Core\WarnDynamicPropertyTrait; +use Atk4\Ui\View; /** * This class generates action, that will be able to loop-back to the callback method. diff --git a/src/JsToast.php b/src/Js/JsToast.php similarity index 98% rename from src/JsToast.php rename to src/Js/JsToast.php index d5a0898636..73f7aa5085 100644 --- a/src/JsToast.php +++ b/src/Js/JsToast.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Atk4\Ui; +namespace Atk4\Ui\Js; use Atk4\Core\DiContainerTrait; diff --git a/src/JsVueService.php b/src/Js/JsVueService.php similarity index 98% rename from src/JsVueService.php rename to src/Js/JsVueService.php index d7f6a0fbdd..191e99546e 100644 --- a/src/JsVueService.php +++ b/src/Js/JsVueService.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Atk4\Ui; +namespace Atk4\Ui\Js; use Atk4\Core\WarnDynamicPropertyTrait; diff --git a/src/JsCallback.php b/src/JsCallback.php index f89340d39b..9f77973f8a 100644 --- a/src/JsCallback.php +++ b/src/JsCallback.php @@ -4,6 +4,11 @@ namespace Atk4\Ui; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsChain; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsExpressionable; + class JsCallback extends Callback { /** @var array Holds information about arguments passed in to the callback. */ diff --git a/src/JsPaginator.php b/src/JsPaginator.php index c438dd0931..c910ef7366 100644 --- a/src/JsPaginator.php +++ b/src/JsPaginator.php @@ -4,6 +4,8 @@ namespace Atk4\Ui; +use Atk4\Ui\Js\Jquery; + /** * Paginate content using scroll event in JS. */ diff --git a/src/JsSortable.php b/src/JsSortable.php index f080fe468c..8a7abb8761 100644 --- a/src/JsSortable.php +++ b/src/JsSortable.php @@ -4,6 +4,8 @@ namespace Atk4\Ui; +use Atk4\Ui\Js\JsChain; + class JsSortable extends JsCallback { /** @var string The html element that contains others element for reordering. */ diff --git a/src/JsSse.php b/src/JsSse.php index 113b4ef2a1..24bdfcf62e 100644 --- a/src/JsSse.php +++ b/src/JsSse.php @@ -5,10 +5,10 @@ namespace Atk4\Ui; use Atk4\Core\HookTrait; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsExpressionable; -/** - * Implements a class that can be mapped into arbitrary JavaScript expression. - */ class JsSse extends JsCallback { use HookTrait; diff --git a/src/Layout/Admin.php b/src/Layout/Admin.php index 98ec8353bb..abdfa56be2 100644 --- a/src/Layout/Admin.php +++ b/src/Layout/Admin.php @@ -6,7 +6,7 @@ use Atk4\Ui\Header; use Atk4\Ui\Icon; -use Atk4\Ui\Jquery; +use Atk4\Ui\Js\Jquery; use Atk4\Ui\Layout; use Atk4\Ui\Menu; use Atk4\Ui\MenuItem; diff --git a/src/Layout/Maestro.php b/src/Layout/Maestro.php index 6edb202220..2085c33386 100644 --- a/src/Layout/Maestro.php +++ b/src/Layout/Maestro.php @@ -4,7 +4,7 @@ namespace Atk4\Ui\Layout; -use Atk4\Ui\Jquery; +use Atk4\Ui\Js\Jquery; use Atk4\Ui\Menu; use Atk4\Ui\MenuItem; diff --git a/src/Layout/NavigableInterface.php b/src/Layout/NavigableInterface.php index 14e89d026a..17cf6103f5 100644 --- a/src/Layout/NavigableInterface.php +++ b/src/Layout/NavigableInterface.php @@ -4,7 +4,7 @@ namespace Atk4\Ui\Layout; -use Atk4\Ui\JsExpressionable; +use Atk4\Ui\Js\JsExpressionable; use Atk4\Ui\Menu; use Atk4\Ui\MenuItem; diff --git a/src/Loader.php b/src/Loader.php index 104b5d7e0d..443f9ae39e 100644 --- a/src/Loader.php +++ b/src/Loader.php @@ -4,6 +4,8 @@ namespace Atk4\Ui; +use Atk4\Ui\Js\JsChain; + /** * Dynamically render it's content. * To provide content for a loader, use set() callback. diff --git a/src/Menu.php b/src/Menu.php index b3d4082088..ff013373f1 100644 --- a/src/Menu.php +++ b/src/Menu.php @@ -5,6 +5,7 @@ namespace Atk4\Ui; use Atk4\Data\Model; +use Atk4\Ui\Js\JsExpressionable; class Menu extends View { diff --git a/src/Modal.php b/src/Modal.php index a0bc00e823..b5b8d54327 100644 --- a/src/Modal.php +++ b/src/Modal.php @@ -4,6 +4,9 @@ namespace Atk4\Ui; +use Atk4\Ui\Js\JsChain; +use Atk4\Ui\Js\JsExpressionable; + /** * This class add modal dialog to a page. * diff --git a/src/Paginator.php b/src/Paginator.php index 5cd8787789..608493e364 100644 --- a/src/Paginator.php +++ b/src/Paginator.php @@ -4,6 +4,9 @@ namespace Atk4\Ui; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsReload; + class Paginator extends View { public $ui = 'pagination menu'; diff --git a/src/Panel/Right.php b/src/Panel/Right.php index 6318b5ae3f..fbad4aaf54 100644 --- a/src/Panel/Right.php +++ b/src/Panel/Right.php @@ -6,9 +6,9 @@ use Atk4\Core\Factory; use Atk4\Ui\Button; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsChain; -use Atk4\Ui\JsExpression; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsChain; +use Atk4\Ui\Js\JsExpression; use Atk4\Ui\Modal; use Atk4\Ui\View; diff --git a/src/Popup.php b/src/Popup.php index b5b352f1c7..09bcad05e2 100644 --- a/src/Popup.php +++ b/src/Popup.php @@ -4,6 +4,9 @@ namespace Atk4\Ui; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; + /** * Implement popup view. * diff --git a/src/ProgressBar.php b/src/ProgressBar.php index cb8f76de98..1c16d957ae 100644 --- a/src/ProgressBar.php +++ b/src/ProgressBar.php @@ -4,6 +4,8 @@ namespace Atk4\Ui; +use Atk4\Ui\Js\JsExpressionable; + /** * $bar = ProgressBar::addTo($app, [10, 'label' => 'Processing files']);. */ diff --git a/src/Table.php b/src/Table.php index 153569ce2e..86886d07a8 100644 --- a/src/Table.php +++ b/src/Table.php @@ -7,6 +7,10 @@ use Atk4\Core\Factory; use Atk4\Data\Field; use Atk4\Data\Model; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsChain; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsExpressionable; class Table extends Lister { diff --git a/src/Table/Column.php b/src/Table/Column.php index 7d322410bc..bc20e47588 100644 --- a/src/Table/Column.php +++ b/src/Table/Column.php @@ -6,9 +6,9 @@ use Atk4\Data\Field; use Atk4\Data\Model; -use Atk4\Ui\Jquery; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpression; use Atk4\Ui\JsCallback; -use Atk4\Ui\JsExpression; use Atk4\Ui\Popup; use Atk4\Ui\Table; diff --git a/src/Table/Column/ActionButtons.php b/src/Table/Column/ActionButtons.php index fc776248b3..0aa44caeb5 100644 --- a/src/Table/Column/ActionButtons.php +++ b/src/Table/Column/ActionButtons.php @@ -8,7 +8,7 @@ use Atk4\Data\Field; use Atk4\Data\Model; use Atk4\Ui\Button; -use Atk4\Ui\JsChain; +use Atk4\Ui\Js\JsChain; use Atk4\Ui\Modal; use Atk4\Ui\Table; use Atk4\Ui\UserAction\ExecutorInterface; diff --git a/src/Table/Column/ActionMenu.php b/src/Table/Column/ActionMenu.php index 7ae676fd53..f00758a95e 100644 --- a/src/Table/Column/ActionMenu.php +++ b/src/Table/Column/ActionMenu.php @@ -7,8 +7,8 @@ use Atk4\Core\Factory; use Atk4\Data\Field; use Atk4\Data\Model; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsChain; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsChain; use Atk4\Ui\Table; use Atk4\Ui\UserAction\ExecutorInterface; use Atk4\Ui\View; diff --git a/src/Table/Column/Checkbox.php b/src/Table/Column/Checkbox.php index aba234ab61..49dfca4646 100644 --- a/src/Table/Column/Checkbox.php +++ b/src/Table/Column/Checkbox.php @@ -6,7 +6,7 @@ use Atk4\Data\Field; use Atk4\Ui\Exception; -use Atk4\Ui\JsExpression; +use Atk4\Ui\Js\JsExpression; use Atk4\Ui\Table; /** diff --git a/src/Table/Column/Delete.php b/src/Table/Column/Delete.php index acbfcadd1f..d6da335365 100644 --- a/src/Table/Column/Delete.php +++ b/src/Table/Column/Delete.php @@ -6,7 +6,7 @@ use Atk4\Data\Field; use Atk4\Ui\CallbackLater; -use Atk4\Ui\Jquery; +use Atk4\Ui\Js\Jquery; use Atk4\Ui\Table; /** diff --git a/src/Table/Column/FilterPopup.php b/src/Table/Column/FilterPopup.php index 03b7b10233..b2daa3b267 100644 --- a/src/Table/Column/FilterPopup.php +++ b/src/Table/Column/FilterPopup.php @@ -8,8 +8,8 @@ use Atk4\Data\Model; use Atk4\Ui\Button; use Atk4\Ui\Form; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsReload; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsReload; use Atk4\Ui\Popup; use Atk4\Ui\View; diff --git a/src/UserAction/BasicExecutor.php b/src/UserAction/BasicExecutor.php index 40fb67c655..d5f3e6e69d 100644 --- a/src/UserAction/BasicExecutor.php +++ b/src/UserAction/BasicExecutor.php @@ -9,8 +9,8 @@ use Atk4\Ui\Button; use Atk4\Ui\Exception; use Atk4\Ui\Header; -use Atk4\Ui\JsExpressionable; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsExpressionable; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Message; use Atk4\Ui\View; diff --git a/src/UserAction/ConfirmationExecutor.php b/src/UserAction/ConfirmationExecutor.php index 9f91537f9b..1edf8a0933 100644 --- a/src/UserAction/ConfirmationExecutor.php +++ b/src/UserAction/ConfirmationExecutor.php @@ -9,9 +9,9 @@ use Atk4\Data\Model\UserAction; use Atk4\Ui\Button; use Atk4\Ui\Exception; -use Atk4\Ui\JsExpressionable; -use Atk4\Ui\JsFunction; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsExpressionable; +use Atk4\Ui\Js\JsFunction; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Loader; use Atk4\Ui\Modal; use Atk4\Ui\Text; diff --git a/src/UserAction/JsCallbackExecutor.php b/src/UserAction/JsCallbackExecutor.php index ff551cd1bc..f9ff491bff 100644 --- a/src/UserAction/JsCallbackExecutor.php +++ b/src/UserAction/JsCallbackExecutor.php @@ -6,10 +6,10 @@ use Atk4\Core\HookTrait; use Atk4\Data\Model; -use Atk4\Ui\Jquery; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsExpressionable; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\JsCallback; -use Atk4\Ui\JsExpressionable; -use Atk4\Ui\JsToast; use Atk4\Ui\View; /** diff --git a/src/UserAction/JsExecutorInterface.php b/src/UserAction/JsExecutorInterface.php index 90dba81d1a..23bee8db5f 100644 --- a/src/UserAction/JsExecutorInterface.php +++ b/src/UserAction/JsExecutorInterface.php @@ -4,7 +4,7 @@ namespace Atk4\Ui\UserAction; -use Atk4\Ui\JsExpressionable; +use Atk4\Ui\Js\JsExpressionable; /** * Add js trigger for executing an action. diff --git a/src/UserAction/ModalExecutor.php b/src/UserAction/ModalExecutor.php index ff85812b7c..540554f427 100644 --- a/src/UserAction/ModalExecutor.php +++ b/src/UserAction/ModalExecutor.php @@ -7,8 +7,8 @@ use Atk4\Core\HookTrait; use Atk4\Data\Model; use Atk4\Ui\Exception; -use Atk4\Ui\JsFunction; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsFunction; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Loader; use Atk4\Ui\Modal; use Atk4\Ui\View; diff --git a/src/UserAction/PanelExecutor.php b/src/UserAction/PanelExecutor.php index f8c672ab14..00525bebe0 100644 --- a/src/UserAction/PanelExecutor.php +++ b/src/UserAction/PanelExecutor.php @@ -7,7 +7,7 @@ use Atk4\Core\HookTrait; use Atk4\Data\Model; use Atk4\Ui\Header; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Loader; use Atk4\Ui\Panel\Right; use Atk4\Ui\View; diff --git a/src/UserAction/StepExecutorTrait.php b/src/UserAction/StepExecutorTrait.php index 590b8c54af..a6983bfbda 100644 --- a/src/UserAction/StepExecutorTrait.php +++ b/src/UserAction/StepExecutorTrait.php @@ -10,8 +10,8 @@ use Atk4\Data\ValidationException; use Atk4\Ui\Button; use Atk4\Ui\Form; -use Atk4\Ui\JsExpressionable; -use Atk4\Ui\JsFunction; +use Atk4\Ui\Js\JsExpressionable; +use Atk4\Ui\Js\JsFunction; use Atk4\Ui\Loader; use Atk4\Ui\Message; use Atk4\Ui\View; diff --git a/src/UserAction/VpExecutor.php b/src/UserAction/VpExecutor.php index 36368e3946..aaa5522f21 100644 --- a/src/UserAction/VpExecutor.php +++ b/src/UserAction/VpExecutor.php @@ -9,8 +9,8 @@ use Atk4\Data\Model; use Atk4\Ui\Button; use Atk4\Ui\Header; -use Atk4\Ui\JsChain; -use Atk4\Ui\JsToast; +use Atk4\Ui\Js\JsChain; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\Loader; use Atk4\Ui\View; use Atk4\Ui\VirtualPage; diff --git a/src/View.php b/src/View.php index b29b33d45b..7c09d02861 100644 --- a/src/View.php +++ b/src/View.php @@ -6,6 +6,13 @@ use Atk4\Data\Model; use Atk4\Data\Persistence; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsChain; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsExpressionable; +use Atk4\Ui\Js\JsFunction; +use Atk4\Ui\Js\JsReload; +use Atk4\Ui\Js\JsVueService; use Atk4\Ui\UserAction\ExecutorFactory; /** diff --git a/src/VueComponent/InlineEdit.php b/src/VueComponent/InlineEdit.php index a2067c3915..17048ffe55 100644 --- a/src/VueComponent/InlineEdit.php +++ b/src/VueComponent/InlineEdit.php @@ -7,8 +7,8 @@ use Atk4\Data\Model; use Atk4\Data\ValidationException; use Atk4\Ui\Exception; +use Atk4\Ui\Js\JsToast; use Atk4\Ui\JsCallback; -use Atk4\Ui\JsToast; use Atk4\Ui\View; /** diff --git a/src/VueComponent/ItemSearch.php b/src/VueComponent/ItemSearch.php index 20dabac7c4..7ff365431e 100644 --- a/src/VueComponent/ItemSearch.php +++ b/src/VueComponent/ItemSearch.php @@ -5,7 +5,7 @@ namespace Atk4\Ui\VueComponent; use Atk4\Data\Model; -use Atk4\Ui\JsVueService; +use Atk4\Ui\Js\JsVueService; use Atk4\Ui\View; /** diff --git a/src/Wizard.php b/src/Wizard.php index d06b97d82a..3f9a21d26d 100644 --- a/src/Wizard.php +++ b/src/Wizard.php @@ -5,6 +5,7 @@ namespace Atk4\Ui; use Atk4\Core\Factory; +use Atk4\Ui\Js\JsExpression; class Wizard extends View { diff --git a/tests/JsIntegrationTest.php b/tests/JsIntegrationTest.php index f687f80d3e..d002a302c5 100644 --- a/tests/JsIntegrationTest.php +++ b/tests/JsIntegrationTest.php @@ -7,8 +7,8 @@ use Atk4\Core\Phpunit\TestCase; use Atk4\Ui\Button; use Atk4\Ui\Exception; +use Atk4\Ui\Js\JsExpression; use Atk4\Ui\JsCallback; -use Atk4\Ui\JsExpression; use Atk4\Ui\View; class JsIntegrationTest extends TestCase diff --git a/tests/JsTest.php b/tests/JsTest.php index c8cdf19cc4..2764043733 100644 --- a/tests/JsTest.php +++ b/tests/JsTest.php @@ -7,10 +7,10 @@ use Atk4\Core\Phpunit\TestCase; use Atk4\Ui\App; use Atk4\Ui\Exception; -use Atk4\Ui\Jquery; -use Atk4\Ui\JsChain; -use Atk4\Ui\JsExpression; -use Atk4\Ui\JsFunction; +use Atk4\Ui\Js\Jquery; +use Atk4\Ui\Js\JsChain; +use Atk4\Ui\Js\JsExpression; +use Atk4\Ui\Js\JsFunction; class JsTest extends TestCase {