Suggestion: Make the overlay size width in multiurlpicker configurable (#10992)
This commit is contained in:
@@ -83,6 +83,7 @@ function multiUrlPickerController($scope, localizationService, entityResource, i
|
||||
dataTypeKey: $scope.model.dataTypeKey,
|
||||
ignoreUserStartNodes : ($scope.model.config && $scope.model.config.ignoreUserStartNodes) ? $scope.model.config.ignoreUserStartNodes : "0",
|
||||
hideAnchor: $scope.model.config && $scope.model.config.hideAnchor ? true : false,
|
||||
size: $scope.model.config.overlayWidthSize,
|
||||
submit: function (model) {
|
||||
if (model.target.url || model.target.anchor) {
|
||||
// if an anchor exists, check that it is appropriately prefixed
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
angular.module("umbraco").controller("Umbraco.PrevalueEditors.MultiUrlPickerController",
|
||||
function ($scope) {
|
||||
if (!$scope.model.value) {
|
||||
$scope.model.value = "small";
|
||||
}
|
||||
});
|
||||
@@ -0,0 +1,9 @@
|
||||
<div ng-controller="Umbraco.PrevalueEditors.MultiUrlPickerController">
|
||||
<div class="vertical-align-items">
|
||||
<select ng-model="model.value">
|
||||
<option value="small">Small</option>
|
||||
<option value="medium">Medium</option>
|
||||
<option value="large">Large</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
@@ -11,6 +11,9 @@ namespace Umbraco.Web.PropertyEditors
|
||||
[ConfigurationField("maxNumber", "Maximum number of items", "number")]
|
||||
public int MaxNumber { get; set; }
|
||||
|
||||
[ConfigurationField("overlayWidthSize", "Overlay Width Size", "views/propertyeditors/multiurlpicker/multiurlpicker.prevalues.html")]
|
||||
public string OverlayWidthSize { get; set; }
|
||||
|
||||
[ConfigurationField(Core.Constants.DataTypes.ReservedPreValueKeys.IgnoreUserStartNodes,
|
||||
"Ignore User Start Nodes", "boolean",
|
||||
Description = "Selecting this option allows a user to choose nodes that they normally don't have access to.")]
|
||||
|
||||
Reference in New Issue
Block a user