1 // https://civicrm.org/licensing
2 (function(angular
, $, _
) {
5 // Menu item to control the background property of a node
6 angular
.module('afGuiEditor').component('afGuiMenuItemBackground', {
7 templateUrl
: '~/afGuiEditor/afGuiMenuItemBackground.html',
11 controller: function($scope
, afAdmin
) {
12 var ts
= $scope
.ts
= CRM
.ts(),
15 $scope
.getSetBackgroundColor = function(color
) {
16 if (!arguments
.length
) {
17 return afAdmin
.getStyles(ctrl
.node
)['background-color'] || '#ffffff';
19 afAdmin
.setStyle(ctrl
.node
, 'background-color', color
);
24 })(angular
, CRM
.$, CRM
._
);