Merge branch 'dev-v8' into temp8-ui-use-umb-checkbox-for-all-variants-dialogs
This commit is contained in:
443
src/Umbraco.Web.UI.Client/package-lock.json
generated
443
src/Umbraco.Web.UI.Client/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -19,9 +19,15 @@ angular.module("umbraco.directives")
|
||||
promises.push(assetsService.loadJs("lib/tinymce/tinymce.min.js", scope));
|
||||
}
|
||||
|
||||
var toolbar = ["code", "styleselect", "bold", "italic", "alignleft", "aligncenter", "alignright", "bullist", "numlist", "link", "umbmediapicker", "umbembeddialog"];
|
||||
if (scope.configuration && scope.configuration.toolbar) {
|
||||
toolbar = scope.configuration.toolbar;
|
||||
var editorConfig = scope.configuration ? scope.configuration : null;
|
||||
if (!editorConfig || angular.isString(editorConfig)) {
|
||||
editorConfig = tinyMceService.defaultPrevalues();
|
||||
//for the grid by default, we don't want to include the macro toolbar
|
||||
editorConfig.toolbar = _.without(editorConfig, "umbmacro");
|
||||
}
|
||||
//make sure there's a max image size
|
||||
if (!scope.configuration.maxImageSize && scope.configuration.maxImageSize !== 0) {
|
||||
editorConfig.maxImageSize = tinyMceService.defaultPrevalues().maxImageSize;
|
||||
}
|
||||
|
||||
//stores a reference to the editor
|
||||
@@ -29,9 +35,9 @@ angular.module("umbraco.directives")
|
||||
|
||||
promises.push(tinyMceService.getTinyMceEditorConfig({
|
||||
htmlId: scope.uniqueId,
|
||||
stylesheets: scope.configuration ? scope.configuration.stylesheets : null,
|
||||
toolbar: toolbar,
|
||||
mode: scope.configuration.mode
|
||||
stylesheets: editorConfig.stylesheets,
|
||||
toolbar: editorConfig.toolbar,
|
||||
mode: editorConfig.mode
|
||||
}));
|
||||
|
||||
// pin toolbar to top of screen if we have focus and it scrolls off the screen
|
||||
@@ -46,9 +52,16 @@ angular.module("umbraco.directives")
|
||||
|
||||
$q.all(promises).then(function (result) {
|
||||
|
||||
var tinyMceEditorConfig = result[promises.length - 1];
|
||||
var standardConfig = result[promises.length - 1];
|
||||
|
||||
tinyMceEditorConfig.setup = function (editor) {
|
||||
//create a baseline Config to extend upon
|
||||
var baseLineConfigObj = {
|
||||
maxImageSize: editorConfig.maxImageSize
|
||||
};
|
||||
|
||||
angular.extend(baseLineConfigObj, standardConfig);
|
||||
|
||||
baseLineConfigObj.setup = function (editor) {
|
||||
|
||||
//set the reference
|
||||
tinyMceEditor = editor;
|
||||
@@ -111,7 +124,7 @@ angular.module("umbraco.directives")
|
||||
//the elements needed
|
||||
$timeout(function () {
|
||||
tinymce.DOM.events.domLoaded = true;
|
||||
tinymce.init(tinyMceEditorConfig);
|
||||
tinymce.init(baseLineConfigObj);
|
||||
}, 150, false);
|
||||
}
|
||||
|
||||
|
||||
@@ -301,6 +301,19 @@ function contentEditingHelper(fileManager, $q, $location, $routeParams, notifica
|
||||
return allProps;
|
||||
},
|
||||
|
||||
/**
|
||||
* @ngdoc method
|
||||
* @name umbraco.services.contentEditingHelper#buildCompositeVariantId
|
||||
* @methodOf umbraco.services.contentEditingHelper
|
||||
* @function
|
||||
*
|
||||
* @description
|
||||
* Returns a id for the variant that is unique between all variants on the content
|
||||
*/
|
||||
buildCompositeVariantId: function (variant) {
|
||||
return (variant.language ? variant.language.culture : "invariant") + "_" + (variant.segment ? variant.segment : "");
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* @ngdoc method
|
||||
|
||||
@@ -13,23 +13,25 @@
|
||||
border: none;
|
||||
border-radius: 0;
|
||||
overflow-y: auto;
|
||||
background-color: @purple-d2;
|
||||
background-color: @blueNight;
|
||||
}
|
||||
|
||||
.login-overlay__background-image {
|
||||
background-position: center center;
|
||||
background-repeat: no-repeat;
|
||||
background-size: cover;
|
||||
background-image: url('../img/login.jpg');
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
position: absolute;
|
||||
opacity: 0.05;
|
||||
}
|
||||
|
||||
.login-overlay__logo {
|
||||
position: absolute;
|
||||
top: 22px;
|
||||
left: 25px;
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
|
||||
@@ -113,7 +113,12 @@ var app = angular.module("umbraco.preview", ['umbraco.resources', 'umbraco.servi
|
||||
$scope.exitPreview = function () {
|
||||
|
||||
var culture = $location.search().culture || getParameterByName("culture");
|
||||
var relativeUrl = "/" + $scope.pageId +'?culture='+ culture;
|
||||
var relativeUrl = "/" + $scope.pageId;
|
||||
|
||||
if(culture){
|
||||
relativeUrl +='?culture='+ culture;
|
||||
}
|
||||
|
||||
window.top.location.href = "../preview/end?redir=" + encodeURIComponent(relativeUrl);
|
||||
};
|
||||
|
||||
|
||||
@@ -2,10 +2,10 @@
|
||||
|
||||
<div id="login" class="umb-modalcolumn umb-dialog" ng-class="{'show-validation': vm.loginForm.$invalid}" ng-cloak>
|
||||
|
||||
<div class="login-overlay__background-image" ng-if="vm.backgroundImage" ng-style="{'background-image':'url(' + vm.backgroundImage + ')'}"></div>
|
||||
<div class="login-overlay__background-image" ng-style="{'background-image': 'url('+vm.backgroundImage+')'}"></div>
|
||||
|
||||
<div class="login-overlay__logo">
|
||||
<img ng-src="assets/img/application/logo.png" ng-srcset="assets/img/application/logo@2x.png 2x, assets/img/application/logo@3x.png 3x">
|
||||
<img src="assets/img/application/umbraco_logo_white.svg">
|
||||
</div>
|
||||
|
||||
<div ng-show="vm.invitedUser != null" class="umb-login-container">
|
||||
@@ -37,11 +37,11 @@
|
||||
<span class="help-inline" ng-message="required"><localize key="general_required">Required</localize></span>
|
||||
<span class="help-inline" ng-message="valCompare"><localize key="user_passwordMismatch">The confirmed password doesn't match the new password!</localize></span>
|
||||
</span>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="flex justify-between items-center">
|
||||
<umb-button
|
||||
<umb-button
|
||||
type="submit"
|
||||
button-style="success"
|
||||
state="vm.invitedUserPasswordModel.buttonState"
|
||||
@@ -58,7 +58,7 @@
|
||||
|
||||
<ng-form name="vm.avatarForm">
|
||||
|
||||
<umb-progress-bar
|
||||
<umb-progress-bar
|
||||
style="max-width: 100px; margin-bottom: 5px;"
|
||||
ng-show="vm.avatarFile.uploadStatus === 'uploading'"
|
||||
progress="{{ vm.avatarFile.uploadProgress }}"
|
||||
@@ -77,7 +77,7 @@
|
||||
ngf-pattern="{{vm.avatarFile.acceptedFileTypes}}"
|
||||
ngf-max-size="{{ vm.avatarFile.maxFileSize }}">
|
||||
|
||||
<umb-avatar
|
||||
<umb-avatar
|
||||
color="gray"
|
||||
size="xl"
|
||||
unknown-char="+"
|
||||
@@ -94,7 +94,7 @@
|
||||
<localize key="user_userinviteAvatarMessage"></localize>
|
||||
</p>
|
||||
<div class="flex justify-center items-center">
|
||||
<umb-button
|
||||
<umb-button
|
||||
type="button"
|
||||
button-style="success"
|
||||
label="Done"
|
||||
@@ -102,7 +102,7 @@
|
||||
</umb-button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
<div ng-show="vm.invitedUser == null && vm.inviteStep === 3" ng-if="vm.inviteStep === 3" class="umb-login-container">
|
||||
<div class="form">
|
||||
@@ -169,7 +169,7 @@
|
||||
</div>
|
||||
|
||||
<div class="flex justify-between items-center">
|
||||
<umb-button
|
||||
<umb-button
|
||||
button-style="success"
|
||||
size="m"
|
||||
label-key="general_login"
|
||||
@@ -261,4 +261,4 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
(function () {
|
||||
"use strict";
|
||||
|
||||
function PublishController($scope, localizationService) {
|
||||
function PublishController($scope, localizationService, contentEditingHelper) {
|
||||
|
||||
var vm = this;
|
||||
vm.loading = true;
|
||||
@@ -129,8 +129,9 @@
|
||||
|
||||
_.each(vm.variants,
|
||||
function (variant) {
|
||||
|
||||
variant.compositeId = variant.language.culture + "_" + (variant.segment ? variant.segment : "");
|
||||
|
||||
variant.compositeId = contentEditingHelper.buildCompositeVariantId(variant);
|
||||
|
||||
variant.htmlId = "_content_variant_" + variant.compositeId;
|
||||
|
||||
// reset to not be published
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
(function () {
|
||||
"use strict";
|
||||
|
||||
function SaveContentController($scope, localizationService) {
|
||||
function SaveContentController($scope, localizationService, contentEditingHelper) {
|
||||
|
||||
var vm = this;
|
||||
vm.loading = true;
|
||||
@@ -75,7 +75,7 @@
|
||||
|
||||
_.each(vm.variants,
|
||||
function (variant) {
|
||||
variant.compositeId = variant.language.culture + "_" + (variant.segment ? variant.segment : "");
|
||||
variant.compositeId = contentEditingHelper.buildCompositeVariantId(variant);
|
||||
variant.htmlId = "_content_variant_" + variant.compositeId;
|
||||
|
||||
//check for pristine variants
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
(function () {
|
||||
"use strict";
|
||||
|
||||
function ScheduleContentController($scope, $timeout, localizationService, dateHelper, userService) {
|
||||
function ScheduleContentController($scope, $timeout, localizationService, dateHelper, userService, contentEditingHelper) {
|
||||
|
||||
var vm = this;
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
|
||||
_.each(vm.variants,
|
||||
function (variant) {
|
||||
variant.compositeId = variant.language.culture + "_" + (variant.segment ? variant.segment : "");
|
||||
variant.compositeId = contentEditingHelper.buildCompositeVariantId(variant);
|
||||
variant.htmlId = "_content_variant_" + variant.compositeId;
|
||||
|
||||
//check for pristine variants
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
(function () {
|
||||
"use strict";
|
||||
|
||||
function SendToPublishController($scope, localizationService) {
|
||||
function SendToPublishController($scope, localizationService, contentEditingHelper) {
|
||||
|
||||
var vm = this;
|
||||
vm.loading = true;
|
||||
@@ -25,7 +25,7 @@
|
||||
if (vm.variants.length !== 0) {
|
||||
_.each(vm.variants,
|
||||
function (variant) {
|
||||
variant.compositeId = variant.language.culture + "_" + (variant.segment ? variant.segment : "");
|
||||
variant.compositeId = contentEditingHelper.buildCompositeVariantId(variant);
|
||||
variant.htmlId = "_content_variant_" + variant.compositeId;
|
||||
});
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
(function () {
|
||||
"use strict";
|
||||
|
||||
function UnpublishController($scope, localizationService) {
|
||||
function UnpublishController($scope, localizationService, contentEditingHelper) {
|
||||
|
||||
var vm = this;
|
||||
var autoSelectedVariants = [];
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
_.each(vm.variants,
|
||||
function (variant) {
|
||||
variant.compositeId = variant.language.culture + "_" + (variant.segment ? variant.segment : "");
|
||||
variant.compositeId = contentEditingHelper.buildCompositeVariantId(variant);
|
||||
variant.htmlId = "_content_variant_" + variant.compositeId;
|
||||
});
|
||||
|
||||
@@ -57,7 +57,7 @@
|
||||
});
|
||||
$scope.model.disableSubmitButton = !firstSelected; //disable submit button if there is none selected
|
||||
|
||||
// if a mandatory variant is selected we want to selet all other variants
|
||||
// if a mandatory variant is selected we want to select all other variants
|
||||
// and disable selection for the others
|
||||
if(selectedVariant.save && selectedVariant.language.isMandatory) {
|
||||
|
||||
|
||||
@@ -17,12 +17,13 @@ angular.module("umbraco")
|
||||
if (!editorConfig || angular.isString(editorConfig)) {
|
||||
editorConfig = tinyMceService.defaultPrevalues();
|
||||
}
|
||||
|
||||
var promises = [];
|
||||
if (!editorConfig.maxImageSize && editorConfig.maxImageSize != 0) {
|
||||
//make sure there's a max image size
|
||||
if (!editorConfig.maxImageSize && editorConfig.maxImageSize !== 0) {
|
||||
editorConfig.maxImageSize = tinyMceService.defaultPrevalues().maxImageSize;
|
||||
}
|
||||
|
||||
var promises = [];
|
||||
|
||||
//queue file loading
|
||||
if (typeof tinymce === "undefined") { // Don't reload tinymce if already loaded
|
||||
promises.push(assetsService.loadJs("lib/tinymce/tinymce.min.js", $scope));
|
||||
@@ -43,7 +44,7 @@ angular.module("umbraco")
|
||||
|
||||
var standardConfig = result[promises.length - 1];
|
||||
|
||||
//create a baseline Config to exten upon
|
||||
//create a baseline Config to extend upon
|
||||
var baseLineConfigObj = {
|
||||
maxImageSize: editorConfig.maxImageSize
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user