diff options
author | dizzy <diosmosis@users.noreply.github.com> | 2022-08-04 13:27:50 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-04 13:27:50 +0300 |
commit | 5e37e68d44a55bb5cad3520f2efe3166bab10cd5 (patch) | |
tree | de7d1b2a2f9c322cd1771ce7c883f0ca7ee4450c /plugins/ExamplePlugin | |
parent | 763d68a9651efabaf7544bc7d4a3fafda33c57b8 (diff) |
[Vue] remove use of angularjs from ExamplePlugin (#19431)
* remove use of angularjs from ExamplePlugin and remove angularjs generation commands that depend on it
* Allow composer plugins for dev dependency codesniffer to fix travis builds.
* keep dependent class and rename
* update screenshots
* updates expected test files
Co-authored-by: sgiehl <stefan@matomo.org>
Diffstat (limited to 'plugins/ExamplePlugin')
8 files changed, 1 insertions, 114 deletions
diff --git a/plugins/ExamplePlugin/angularjs/directive-component/component.controller.js b/plugins/ExamplePlugin/angularjs/directive-component/component.controller.js deleted file mode 100644 index 1c83121d33..0000000000 --- a/plugins/ExamplePlugin/angularjs/directive-component/component.controller.js +++ /dev/null @@ -1,23 +0,0 @@ -/*! - * Matomo - free/libre analytics platform - * - * @link https://matomo.org - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later - */ -(function () { - angular.module('piwikApp').controller('ComponentController', ComponentController); - - ComponentController.$inject = []; - - function ComponentController() { - // remember to keep controller very simple. Create a service/factory (model) if needed - - var vm = this; - vm.myProperty = 'component'; - vm.doSomething = doSomething; - - function doSomething() { - - } - } -})();
\ No newline at end of file diff --git a/plugins/ExamplePlugin/angularjs/directive-component/component.directive.html b/plugins/ExamplePlugin/angularjs/directive-component/component.directive.html deleted file mode 100644 index 45eb76c0b5..0000000000 --- a/plugins/ExamplePlugin/angularjs/directive-component/component.directive.html +++ /dev/null @@ -1,3 +0,0 @@ -<div class="componentClass"> - {{ componentAs.myProperty }} -</div>
\ No newline at end of file diff --git a/plugins/ExamplePlugin/angularjs/directive-component/component.directive.js b/plugins/ExamplePlugin/angularjs/directive-component/component.directive.js deleted file mode 100644 index 0d7bb2dd84..0000000000 --- a/plugins/ExamplePlugin/angularjs/directive-component/component.directive.js +++ /dev/null @@ -1,44 +0,0 @@ -/*! - * Matomo - free/libre analytics platform - * - * @link https://matomo.org - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later - */ - -/** - * Usage: - * <div piwik-component> - */ -(function () { - angular.module('piwikApp').directive('piwikComponent', piwikComponent); - - piwikComponent.$inject = ['piwik']; - - function piwikComponent(piwik){ - var defaults = { - // showAllSitesItem: 'true' - }; - - return { - restrict: 'A', - scope: { - // showAllSitesItem: '<' - }, - templateUrl: 'plugins/ExamplePlugin/angularjs/directive-component/component.directive.html?cb=' + piwik.cacheBuster, - controller: 'ComponentController', - controllerAs: 'componentAs', - compile: function (element, attrs) { - - for (var index in defaults) { - if (defaults.hasOwnProperty(index) && attrs[index] === undefined) { - attrs[index] = defaults[index]; - } - } - - return function (scope, element, attrs) { - - }; - } - }; - } -})();
\ No newline at end of file diff --git a/plugins/ExamplePlugin/angularjs/directive-component/component.directive.less b/plugins/ExamplePlugin/angularjs/directive-component/component.directive.less deleted file mode 100644 index 625a2a84ef..0000000000 --- a/plugins/ExamplePlugin/angularjs/directive-component/component.directive.less +++ /dev/null @@ -1,3 +0,0 @@ -.componentClass { - // ... -}
\ No newline at end of file diff --git a/plugins/ExamplePlugin/angularjs/example-component/example-component.component.html b/plugins/ExamplePlugin/angularjs/example-component/example-component.component.html deleted file mode 100644 index 45eb76c0b5..0000000000 --- a/plugins/ExamplePlugin/angularjs/example-component/example-component.component.html +++ /dev/null @@ -1,3 +0,0 @@ -<div class="componentClass"> - {{ componentAs.myProperty }} -</div>
\ No newline at end of file diff --git a/plugins/ExamplePlugin/angularjs/example-component/example-component.component.js b/plugins/ExamplePlugin/angularjs/example-component/example-component.component.js deleted file mode 100644 index e9f40184db..0000000000 --- a/plugins/ExamplePlugin/angularjs/example-component/example-component.component.js +++ /dev/null @@ -1,34 +0,0 @@ -/*! - * Matomo - free/libre analytics platform - * - * @link https://matomo.org - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later - */ - -/** - * Usage: - * <piwik-example-component> - */ -(function () { - angular.module('piwikApp').component('piwikComponent', { - templateUrl: 'plugins/ExamplePlugin/angularjs/example-component/example-component.component.html?cb=' + piwik.cacheBuster, - bindings: { - // showAllSitesItem: '<' - }, - controller: ComponentController - }); - - ComponentController.$inject = []; - - function ComponentController() { - // remember to keep controller very simple. Create a service/factory (model) if needed - - var vm = this; - vm.myProperty = 'component'; - vm.doSomething = doSomething; - - function doSomething() { - - } - } -})(); diff --git a/plugins/ExamplePlugin/angularjs/example-component/example-component.component.less b/plugins/ExamplePlugin/angularjs/example-component/example-component.component.less deleted file mode 100644 index 625a2a84ef..0000000000 --- a/plugins/ExamplePlugin/angularjs/example-component/example-component.component.less +++ /dev/null @@ -1,3 +0,0 @@ -.componentClass { - // ... -}
\ No newline at end of file diff --git a/plugins/ExamplePlugin/plugin.json b/plugins/ExamplePlugin/plugin.json index 838953abc7..65ad27e512 100644 --- a/plugins/ExamplePlugin/plugin.json +++ b/plugins/ExamplePlugin/plugin.json @@ -1,6 +1,6 @@ { "name": "ExamplePlugin", - "description": "Matomo Platform showcase: how to create widgets, menus, scheduled tasks, a custom archiver, plugin tests, and an AngularJS component.", + "description": "Matomo Platform showcase: how to create widgets, menus, scheduled tasks, a custom archiver, and plugin tests.", "version": "0.1.0", "theme": false, "require": { |