PDF rausgenommen

This commit is contained in:
aschwarz
2023-01-23 11:03:31 +01:00
parent 82d562a322
commit a6523903eb
28078 changed files with 4247552 additions and 2 deletions

View File

@ -0,0 +1,7 @@
thumbs-up.png
https://www.iconfinder.com/icons/83403/thumbs_up_icon#size=32
Creative Commons (Attribution-Share Alike 3.0 Unported)
thumbs-down.png
https://www.iconfinder.com/icons/83402/down_thumbs_icon#size=32
Creative Commons (Attribution-Share Alike 3.0 Unported)

View File

@ -0,0 +1,29 @@
/*!
* Piwik - free/libre analytics platform
*
* @link http://piwik.org
* @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
*/
(function () {
angular.module('piwikApp').factory('rateFeatureModel', rateFeatureModel);
rateFeatureModel.$inject = ['piwikApi'];
function rateFeatureModel(piwikApi) {
return {
sendFeedbackForFeature: sendFeedbackForFeature
};
function sendFeedbackForFeature (featureName, like, message) {
return piwikApi.fetch({
method: 'Feedback.sendFeedbackForFeature',
featureName: featureName,
like: like ? '1' : '0',
message: message + ''
});
}
}
})();

View File

@ -0,0 +1,33 @@
/*!
* Piwik - free/libre analytics platform
*
* @link http://piwik.org
* @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
*/
(function () {
angular.module('piwikApp').controller('RateFeatureController', RateFeatureController);
RateFeatureController.$inject = ['$scope', 'rateFeatureModel'];
function RateFeatureController($scope, model){
var vm = this;
vm.title = $scope.title;
vm.dislikeFeature = dislikeFeature;
vm.likeFeature = likeFeature;
vm.sendFeedback = sendFeedback;
function dislikeFeature () {
vm.like = false;
}
function likeFeature () {
vm.like = true;
}
function sendFeedback (message) {
model.sendFeedbackForFeature(vm.title, vm.like, message);
vm.ratingDone = true;
}
}
})();

View File

@ -0,0 +1,39 @@
<div title="{{ 'Feedback_RateFeatureTitle'|translate:(rateFeature.title|escape) }}" class="ratefeature">
<div class="iconContainer"
ng-mouseenter="view.expanded=true;"
ng-mouseleave="view.expanded=false">
<img ng-click="rateFeature.likeFeature();view.showFeedbackForm=true;"
class="like-icon"
src="plugins/Feedback/angularjs/ratefeature/thumbs-up.png"/>
<img ng-click="rateFeature.dislikeFeature();view.showFeedbackForm=true;"
class="dislike-icon"
ng-show="view.expanded"
src="plugins/Feedback/angularjs/ratefeature/thumbs-down.png"/>
</div>
<div class="ui-confirm ratefeatureDialog" piwik-dialog="view.showFeedbackForm" yes="rateFeature.sendFeedback(view.feedbackMessage)">
<h2>{{ 'Feedback_RateFeatureThankYouTitle'|translate:title }}</h2>
<p ng-if="rateFeature.like">{{ 'Feedback_RateFeatureLeaveMessageLike'|translate }}</p>
<p ng-if="!rateFeature.like">{{ 'Feedback_RateFeatureLeaveMessageDislike'|translate }}</p>
<br />
<div class="messageContainer">
<textarea ng-model="view.feedbackMessage"></textarea>
</div>
<input type="button"
title="{{ 'Feedback_RateFeatureSendFeedbackInformation'|translate }}"
value="{{ 'Feedback_SendFeedback'|translate }}" role="yes"/>
<input type="button" role="cancel" value="{{ 'General_Cancel'|translate }}"/>
</div>
<div class="ui-confirm ratefeatureDialog" piwik-dialog="rateFeature.ratingDone" yes="">
<h2>{{ 'Feedback_ThankYou'|translate:rateFeature.title }}</h2>
<input type="button" value="{{ 'General_Ok'|translate }}" role="yes"/>
</div>
</div>

View File

@ -0,0 +1,29 @@
/*!
* Piwik - free/libre analytics platform
*
* @link http://piwik.org
* @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
*/
/**
* Usage:
* <div piwik-rate-feature title="My Feature Name">
*/
(function () {
angular.module('piwikApp').directive('piwikRateFeature', piwikRateFeature);
piwikRateFeature.$inject = ['piwik'];
function piwikRateFeature(piwik){
return {
restrict: 'A',
scope: {
title: '@'
},
templateUrl: 'plugins/Feedback/angularjs/ratefeature/ratefeature.directive.html?cb=' + piwik.cacheBuster,
controller: 'RateFeatureController',
controllerAs: 'rateFeature',
};
}
})();

View File

@ -0,0 +1,30 @@
.ratefeatureDialog {
text-align: center;
textarea {
margin-top: 5px;
width: 100%;
height: 80px;
}
}
.ratefeature {
font-size: 1px;
.iconContainer {
display: inline-block;
}
.dislike-icon,
.like-icon {
opacity: 0.2;
width: 22px;
height: 22px;
cursor: pointer;
&:hover {
opacity: 0.9;
}
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB