How to set angular modal custom height and width

I found a way to change the width of the angular mod, so that I could not figure out how to set the height I want. I need a modal width of 400 pixels, a height of 400 pixels. I also need to move it so that it is in the center of the screen. thanks plunkr

$scope.NewJobModal = function () { var modalInstance = $modal.open({ templateUrl: 'views/modals/NewJobModal.html', controller: 'NewJobModalInstanceCtrl', windowClass: 'large-Modal', resolve: { p: function () { return $scope.p; } } }); }; .large-Modal .modal-dialog{ width:30%; } 
+5
source share
1 answer

Two things:

1 - In Plunkr, you indicated that you are not using a .css file. Change src to href.

2 - Then in your css file:

 .large-Modal .modal-dialog{ height: 400px; width:400px; margin: auto; position: absolute; top:0; right: 0; bottom: 0; left: 0; } 
+9
source

Source: https://habr.com/ru/post/1204026/


All Articles