Adds new create dialog option to create a stylesheet as RTE (will set URL location to include rtestyle=true)

This commit is contained in:
Warren Buckley
2018-11-07 10:26:51 +00:00
parent d021505062
commit 7f0099ca57
2 changed files with 12 additions and 0 deletions

View File

@@ -7,11 +7,17 @@
var node = $scope.dialogOptions.currentNode;
vm.createFile = createFile;
vm.createRichtextStyle = createRichtextStyle;
function createFile() {
$location.path("/settings/stylesheets/edit/" + node.id).search("create", "true");
navigationService.hideMenu();
}
function createRichtextStyle() {
$location.path("/settings/stylesheets/edit/" + node.id).search("create", "true").search("rtestyle", "true");
navigationService.hideMenu();
}
}
angular.module("umbraco").controller("Umbraco.Editors.StyleSheets.CreateController", StyleSheetsCreateController);

View File

@@ -10,6 +10,12 @@
<span class="menu-label"><localize key="create_newStyleSheetFile">New style sheet file</localize></span>
</a>
</li>
<li class="umb-action">
<a href="" ng-click="vm.createRichtextStyle()" class="umb-action-link">
<i class="large icon icon-folder"></i>
<span class="menu-label"><localize key="create_newRteStyleSheetFile">New richtext style sheet file</localize></span>
</a>
</li>
</ul>
</div>