Skip to content

Commit 1d51ba4

Browse files
Add ability to use custom template
1 parent d14484f commit 1d51ba4

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

dist/jr-crop.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,8 @@ function($ionicModal, $rootScope, $q) {
269269
height: 0,
270270
aspectRatio: 0,
271271
cancelText: 'Cancel',
272-
chooseText: 'Choose'
272+
chooseText: 'Choose',
273+
template: template
273274
},
274275

275276
crop: function(options) {
@@ -279,7 +280,7 @@ function($ionicModal, $rootScope, $q) {
279280

280281
ionic.extend(scope, options);
281282

282-
scope.modal = $ionicModal.fromTemplate(template, {
283+
scope.modal = $ionicModal.fromTemplate(options.template, {
283284
scope: scope
284285
});
285286

dist/jr-crop.min.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/jr-crop.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,8 @@ function($ionicModal, $rootScope, $q) {
262262
height: 0,
263263
aspectRatio: 0,
264264
cancelText: 'Cancel',
265-
chooseText: 'Choose'
265+
chooseText: 'Choose',
266+
template: template
266267
},
267268

268269
crop: function(options) {
@@ -272,7 +273,7 @@ function($ionicModal, $rootScope, $q) {
272273

273274
ionic.extend(scope, options);
274275

275-
scope.modal = $ionicModal.fromTemplate(template, {
276+
scope.modal = $ionicModal.fromTemplate(options.template, {
276277
scope: scope
277278
});
278279

0 commit comments

Comments
 (0)