cronapp-framework-js 2.8.24 → 2.8.25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/components/crn-button.components.json +2 -12
  2. package/components/crn-enterprise-checkbox.components.json +0 -5
  3. package/components/crn-enterprise-combobox-multiple.components.json +0 -5
  4. package/components/crn-enterprise-dynamic-combobox.components.json +1 -1
  5. package/components/crn-horizontal-container.components.json +1 -12
  6. package/components/crn-icon.components.json +12 -20
  7. package/components/crn-image.components.json +4 -4
  8. package/components/crn-rating.components.json +29 -31
  9. package/components/crn-upload-file.components.json +3 -2
  10. package/components/crn-upload.components.json +2 -2
  11. package/components/css/checkbox-color.css +0 -16
  12. package/components/css/color-default.css +0 -2
  13. package/components/templates/button.template.html +2 -2
  14. package/components/templates/cron-checkbox.template.html +2 -1
  15. package/components/templates/cron-combobox-multiple.template.html +1 -1
  16. package/components/templates/cron-crud.template.html +7 -43
  17. package/components/templates/cron-dynamic-combobox.template.html +3 -2
  18. package/components/templates/fileupload-button.template.html +1 -1
  19. package/components/templates/fileupload.template.html +1 -1
  20. package/components/templates/form.template.html +21 -44
  21. package/components/templates/icon.template.html +1 -1
  22. package/components/templates/image.default.template.html +2 -1
  23. package/components/templates/rating.template.html +6 -6
  24. package/components/templates/social-button-bar.template.html +12 -11
  25. package/components/templates/sub-form.template.html +11 -44
  26. package/components/templates/textinputbutton.template.html +1 -3
  27. package/css/app.css +0 -27
  28. package/dist/components/css/checkbox-color.css +1 -1
  29. package/dist/components/css/color-default.css +1 -1
  30. package/dist/components/templates/button.template.html +1 -1
  31. package/dist/components/templates/cron-checkbox.template.html +1 -1
  32. package/dist/components/templates/cron-combobox-multiple.template.html +1 -1
  33. package/dist/components/templates/cron-crud.template.html +1 -1
  34. package/dist/components/templates/cron-dynamic-combobox.template.html +1 -1
  35. package/dist/components/templates/fileupload-button.template.html +1 -1
  36. package/dist/components/templates/fileupload.template.html +1 -1
  37. package/dist/components/templates/form.template.html +1 -1
  38. package/dist/components/templates/icon.template.html +1 -1
  39. package/dist/components/templates/image.default.template.html +1 -1
  40. package/dist/components/templates/rating.template.html +1 -1
  41. package/dist/components/templates/social-button-bar.template.html +1 -1
  42. package/dist/components/templates/sub-form.template.html +1 -1
  43. package/dist/components/templates/textinputbutton.template.html +1 -1
  44. package/dist/css/app.css +1 -1
  45. package/dist/js/app.js +1 -1
  46. package/dist/js/controllers.js +1 -1
  47. package/dist/js/directives.js +1 -1
  48. package/dist/js/upload.service.js +1 -1
  49. package/js/app.js +21 -39
  50. package/js/controllers.js +11 -18
  51. package/js/directives.js +7 -15
  52. package/js/upload.service.js +3 -7
  53. package/package.json +11 -11
  54. package/components/css/font-size.css +0 -15
  55. package/components/css/image.css +0 -15
  56. package/dist/components/css/font-size.css +0 -1
  57. package/dist/components/css/image.css +0 -1
@@ -1 +1 @@
1
- (function(){function a(a){var b=[].slice.call(arguments,1),c=0;return a.replace(/%s/g,function(){return b[c++]})}angular.module("upload.services",[]).service("UploadService",["$http","$compile","$modal","Upload",function(a,b,c){var d=$("body"),e=angular.element(d.get(0)).scope();this.ensureProps=a=>(a.filter&&(a.filter=a.filter.replace(/\s/g,"")),a),this.upload=function(a){let b=this.ensureProps(a);c.open({templateUrl:"node_modules/cronapp-framework-js/components/upload/upload.html",controller:"UploadController",resolve:{data:function(){return b}}})}.bind(this)}]),angular.module("custom.controllers").controller("UploadController",["$scope","$http","$translate","$stateParams","$location","$http","$modalInstance","data",function(b,c,d,e,f,c,g,h){app.registerEventsCronapi(b,d),b.params=e,b.$http=c;var i=f.search();for(var j in i)i.hasOwnProperty(j)&&(b.params[j]=i[j]);b.files=[],b.uploading=!1,b.uploaded=!0,b.progress=0,b.data=h,b.message=d.instant("Upload.oneFile"),"true"==h.multiple&&(b.message=d.instant("Upload.multipleFile")),h.description&&(b.message=h.description),b.safeApply=safeApply,b.uploadFile=function(e){var f=b.data.scope,g="api/cronapi/upload/"+h.id,j=new FormData;if(0==e.length)this.Notification.error(a(d.instant("Upload.errorValidation"),h.maxSize,h.filter));else{for(var k=0;k<e.length;k++)j.append("file",e[k]),console.log(e[k].$valid);var l=JSON.parse(localStorage.getItem("_u"));this.$promise=c({method:"POST",url:(window.hostApp||"")+g,data:j,headers:{"Content-Type":void 0,"X-AUTH-TOKEN":l?l.token:""},onProgress:function(a){this.safeApply(function(){if(a.lengthComputable){var c=0|100*(a.loaded/a.total);b.progress=c}b.uploading=!0,console.log(c)})}.bind(this)}).then(function(a){f.cronapi.evalInContext(JSON.stringify(a)).then(()=>{b.uploaded=!0,b.uploading=!1,b.close()})}.bind(this)).catch(function(a){let c=a.error;a&&a.data&&(c=a.data.error),this.Notification.error(c),b.uploading=!1,b.close()}.bind(this))}}.bind(b),b.close=function(){g.dismiss("cancel")}}])})(app);
1
+ (function(){function a(a){var b=[].slice.call(arguments,1),c=0;return a.replace(/%s/g,function(){return b[c++]})}angular.module("upload.services",[]).service("UploadService",["$http","$compile","$modal","Upload",function(a,b,c){var d=$("body"),e=angular.element(d.get(0)).scope();this.ensureProps=a=>(a.filter&&(a.filter=a.filter.replace(/\s/g,"")),a),this.upload=function(a){let b=this.ensureProps(a);c.open({templateUrl:"node_modules/cronapp-framework-js/components/upload/upload.html",controller:"UploadController",resolve:{data:function(){return b}}})}.bind(this)}]),angular.module("custom.controllers").controller("UploadController",["$scope","$http","$translate","$stateParams","$location","$http","$modalInstance","data",function(b,c,d,e,f,c,g,h){app.registerEventsCronapi(b,d),b.params=e,b.$http=c;var i=f.search();for(var j in i)i.hasOwnProperty(j)&&(b.params[j]=i[j]);b.files=[],b.uploading=!1,b.uploaded=!0,b.progress=0,b.data=h,b.message=d.instant("Upload.oneFile"),"true"==h.multiple&&(b.message=d.instant("Upload.multipleFile")),h.description&&(b.message=h.description),b.safeApply=safeApply,b.uploadFile=function(e){var f=b.data.scope,g="api/cronapi/upload/"+h.id,j=new FormData;if(0==e.length)this.Notification.error(a(d.instant("Upload.errorValidation"),h.maxSize,h.filter));else{for(var k=0;k<e.length;k++)j.append("file",e[k]),console.log(e[k].$valid);var l=JSON.parse(localStorage.getItem("_u"));this.$promise=c({method:"POST",url:(window.hostApp||"")+g,data:j,headers:{"Content-Type":void 0,"X-AUTH-TOKEN":l?l.token:""},onProgress:function(a){this.safeApply(function(){if(a.lengthComputable){var c=0|100*(a.loaded/a.total);b.progress=c}b.uploading=!0,console.log(c)})}.bind(this)}).success(function(a){f.cronapi.evalInContext(JSON.stringify(a)).then(()=>{b.uploaded=!0,b.uploading=!1,b.close()})}.bind(this)).error(function(a){this.Notification.error(a.error),b.uploading=!1,b.close()}.bind(this))}}.bind(b),b.close=function(){g.dismiss("cancel")}}])})(app);
package/js/app.js CHANGED
@@ -30,14 +30,6 @@ var onloadCallback = function() {
30
30
  window.grecaptcha.reset();
31
31
  };
32
32
 
33
- var getRequestData = data => {
34
- let result = data || {};
35
- if (data.data && typeof data.data === 'object') {
36
- result = data.data;
37
- }
38
- return result;
39
- };
40
-
41
33
  var app = (function() {
42
34
 
43
35
  return angular.module('MyApp', cronappModules)
@@ -49,9 +41,6 @@ var app = (function() {
49
41
  'preferredLocale': 'pt_br',
50
42
  'urlPrefix': ''
51
43
  })
52
- .config(['$locationProvider', function($locationProvider) {
53
- $locationProvider.hashPrefix('');
54
- }])
55
44
  .config([
56
45
  '$httpProvider',
57
46
  function($httpProvider) {
@@ -138,8 +127,6 @@ var app = (function() {
138
127
 
139
128
  var locale = (window.navigator.userLanguage || window.navigator.language).replace('-', '_').toLowerCase();
140
129
  $translateProvider.use(locale);
141
- $translateProvider.preferredLanguage(locale);
142
- $translateProvider.fallbackLanguage('en_us');
143
130
 
144
131
  $translateProvider.useSanitizeValueStrategy('escaped');
145
132
 
@@ -259,7 +246,7 @@ var app = (function() {
259
246
 
260
247
  })
261
248
 
262
- .run(function($rootScope, $state, $stateParams, $timeout, $transitions) {
249
+ .run(function($rootScope, $state, $stateParams, $timeout) {
263
250
  // It's very handy to add references to $state and $stateParams to the $rootScope
264
251
  // so that you can access them from any scope within your applications.For example,
265
252
  // <li ng-class="{ active: $state.includes('contacts.list') }"> will set the <li>
@@ -267,27 +254,26 @@ var app = (function() {
267
254
  $rootScope.$state = $state;
268
255
  $rootScope.$stateParams = $stateParams;
269
256
 
270
- const $stateChangeError = function(error) {
271
- if (error) {
272
- const errorMessage = error.toString();
273
- if (errorMessage.includes('=404')) {
274
- $state.go('404');
275
- }
276
- else if (errorMessage.includes('=403')) {
277
- $state.go('403');
278
- }
279
- else if (errorMessage.includes('=401')) {
280
- localStorage.removeItem('_u');
281
- $state.go('loginReturnUrl', { "returnUrl" : window.location.hash });
282
- } else {
283
- $state.go('404');
257
+ $rootScope.$on('$stateChangeError', function() {
258
+ if (arguments.length >= 6) {
259
+ var requestObj = arguments[5];
260
+ if (requestObj.status === 404 || requestObj.status === 403 || requestObj.status === 401) {
261
+ if (requestObj.status === 404) {
262
+ $state.go('404');
263
+ }
264
+ else if (requestObj.status === 403) {
265
+ $state.go('403');
266
+ }
267
+ else {
268
+ localStorage.removeItem('_u');
269
+ $state.go('loginReturnUrl', { "returnUrl" : window.location.hash });
270
+ }
284
271
  }
285
272
  } else {
286
273
  $state.go('404');
287
274
  }
288
- };
289
-
290
- const $stateChangeSuccess = function(currentRoute) {
275
+ });
276
+ $rootScope.$on('$stateChangeSuccess', function(event, currentRoute, previousRoute) {
291
277
  $timeout(() => {
292
278
  let systemName = $('#projectName').length ? $('#projectName').val() : $('h1:first').length && $('h1:first').text().trim().length ? $('h1:first').text().trim() : '';
293
279
 
@@ -334,11 +320,7 @@ var app = (function() {
334
320
 
335
321
  $rootScope.renderFinished = true;
336
322
  });
337
- };
338
-
339
- $transitions.onSuccess({}, (transition) => $stateChangeSuccess(transition.to()));
340
- $state.defaultErrorHandler(error => $stateChangeError(error));
341
-
323
+ });
342
324
  });
343
325
 
344
326
  }(window));
@@ -437,9 +419,9 @@ app.factory('customTranslateLoader', function ($http, $q) {
437
419
  ].join(''),
438
420
  method: 'GET',
439
421
  params: ''
440
- }, options.$http)).then(function (data) {
441
- deferred.resolve(getRequestData(data));
442
- }).catch(function () {
422
+ }, options.$http)).success(function (data) {
423
+ deferred.resolve(data);
424
+ }).error(function () {
443
425
  deferred.resolve({});
444
426
  });
445
427
 
package/js/controllers.js CHANGED
@@ -6,8 +6,7 @@
6
6
  $http({
7
7
  method: 'GET',
8
8
  url: 'auth/refresh'
9
- }).then(function (data, status, headers, config) {
10
- data = getRequestData(data);
9
+ }).success(function (data, status, headers, config) {
11
10
  //Keeping the user information, the auth/refresh only has name and username info
12
11
  if (localStorage.getItem("_u")) {
13
12
  let currentSession = JSON.parse(localStorage.getItem("_u"));
@@ -22,7 +21,7 @@
22
21
  // refresh time
23
22
  }, (1800 * 1000));
24
23
  success();
25
- }).catch(function () {
24
+ }).error(function () {
26
25
  error();
27
26
  });
28
27
  };
@@ -52,12 +51,12 @@
52
51
  'Content-Type': 'application/x-www-form-urlencoded',
53
52
  'X-AUTH-TOKEN': $location.search().token
54
53
  }
55
- }).then(() => {
54
+ }).success(() => {
56
55
  Notification.info($translate.instant('ResetPasswordSuccess'));
57
56
  passwordNew.value = "";
58
57
  passwordConfirmation.value = "";
59
58
  $state.go('login');
60
- }).catch(data => Notification.error(data));
59
+ }).error(data => Notification.error(data));
61
60
  //
62
61
  }
63
62
  });
@@ -161,7 +160,7 @@
161
160
  url : 'auth',
162
161
  data : $.param(user),
163
162
  headers : headerValues
164
- }).then(handleSuccess).catch(handleError);
163
+ }).success(handleSuccess).error(handleError);
165
164
  };
166
165
 
167
166
  $scope.forgotPassword = function () {
@@ -182,15 +181,14 @@
182
181
  headers: {
183
182
  'Content-Type': 'application/x-www-form-urlencoded'
184
183
  }
185
- }).then(() => {
184
+ }).success(() => {
186
185
  Notification.info($translate.instant('ForgotPasswordSent'));
187
186
  forgotPasswordEmail.value = "";
188
187
  $("#forgotPasswordModal").modal("hide");
189
- }).catch(data => Notification.error(data));
188
+ }).error(data => Notification.error(data));
190
189
  };
191
190
 
192
191
  function handleSuccess(data, status, headers, config) {
193
- data = getRequestData(data);
194
192
  // Store data response on session storage
195
193
  // The local storage will be cleaned when the browser window is closed
196
194
  if(typeof (Storage) !== "undefined") {
@@ -214,8 +212,6 @@
214
212
  }
215
213
 
216
214
  function handleError(data, status, headers, config) {
217
- status = status || data.status;
218
- data = getRequestData(data);
219
215
  let error;
220
216
  if (data !== null && data.message) {
221
217
  let message = JSON.parse(data.message);
@@ -315,10 +311,9 @@
315
311
  headers : {
316
312
  'Content-Type' : 'application/json'
317
313
  }
318
- }).then(clean).catch(clean);
314
+ }).success(clean).error(clean);
319
315
 
320
316
  function clean(result) {
321
- result = getRequestData(result);
322
317
  $rootScope.session = {};
323
318
  if(typeof (Storage) !== "undefined") {
324
319
  localStorage.removeItem("_u");
@@ -348,7 +343,7 @@
348
343
  headers : {
349
344
  'Content-Type' : 'application/x-www-form-urlencoded'
350
345
  }
351
- }).then(changeSuccess).catch(changeError);
346
+ }).success(changeSuccess).error(changeError);
352
347
  }
353
348
 
354
349
  function changeSuccess(data, status, headers, config) {
@@ -357,8 +352,6 @@
357
352
  }
358
353
 
359
354
  function changeError(data, status, headers, config) {
360
- status = status || data.status;
361
- data = getRequestData(data);
362
355
  var error;
363
356
 
364
357
  if (status === 422) {
@@ -446,7 +439,7 @@
446
439
  headers : {
447
440
  'Content-Type' : 'application/x-www-form-urlencoded'
448
441
  }
449
- }).then(changeSuccess).catch(changeError);
442
+ }).success(changeSuccess).error(changeError);
450
443
 
451
444
  function changeSuccess(data, status, headers, config) {
452
445
  $rootScope.session.theme = theme;
@@ -455,7 +448,7 @@
455
448
  }
456
449
 
457
450
  function changeError(data, status, headers, config) {
458
- var error = getRequestData(data);
451
+ var error = data;
459
452
  Notification.error(error);
460
453
  }
461
454
  }
package/js/directives.js CHANGED
@@ -4466,16 +4466,12 @@
4466
4466
  require: 'ngModel',
4467
4467
  link: function(scope, elem, attrs, ngModelCtrl) {
4468
4468
 
4469
+ attrs.theme = $(elem).find('i').attr('xattr-theme');
4470
+ attrs.iconOn = $(elem).find('i').attr('class');
4471
+
4469
4472
  var $elem = $(elem);
4470
4473
  var starArray = [];
4471
4474
 
4472
- var icon = $elem.find('i');
4473
-
4474
- attrs.iconSize = icon[0].dataset.size;
4475
- attrs.iconTheme = icon[0].dataset.theme;
4476
- attrs.iconOn = icon[0].className;
4477
- attrs.iconOn = attrs.iconOn.replace(attrs.iconSize).replace(attrs.iconTheme);
4478
-
4479
4475
  if (attrs.xattrDefaultValue) {
4480
4476
  ngModelCtrl.$viewValue = 0; //set new view value
4481
4477
  ngModelCtrl.$commitViewValue();
@@ -4483,7 +4479,6 @@
4483
4479
 
4484
4480
  for (var i=1;i<=5;i++) {
4485
4481
  starArray.push($(elem).find('i').get(i - 1));
4486
- $(starArray[i-1]).removeClass(attrs.iconOn);
4487
4482
  $(starArray[i-1]).addClass(attrs.iconOff || "fa fa-star-o");
4488
4483
  }
4489
4484
 
@@ -4512,16 +4507,13 @@
4512
4507
  for (var i=1;i<=5;i++) {
4513
4508
  stars[i-1].removeClass(attrs.iconOff || 'fa fa-star-o');
4514
4509
  stars[i-1].removeClass(attrs.iconOn);
4515
- stars[i-1].removeClass(attrs.iconSize);
4516
- stars[i-1].removeClass(attrs.iconTheme);
4510
+ stars[i-1].removeClass(attrs.theme);
4517
4511
  if (i <= value) {
4518
4512
  stars[i-1].addClass(attrs.iconOn);
4519
- stars[i-1].addClass(attrs.iconSize);
4520
- stars[i-1].addClass(attrs.iconTheme);
4513
+ stars[i-1].addClass(attrs.theme);
4521
4514
  } else {
4522
4515
  stars[i-1].addClass(attrs.iconOff || 'fa fa-star-o');
4523
- stars[i-1].addClass(attrs.iconSize);
4524
- stars[i-1].addClass(attrs.iconTheme);
4516
+ stars[i-1].addClass(attrs.theme);
4525
4517
  }
4526
4518
  }
4527
4519
  return value;
@@ -4648,7 +4640,7 @@
4648
4640
  //Somente fica na vertical se for o menu principal da IDE (E estiver configurado para isso)
4649
4641
  let isVertical = element.closest('.crn-navigator-vertical').length;
4650
4642
 
4651
- var TEMPLATE_MAIN = '<ul class="nav navbar-nav ' + (isVertical ? 'col-md-12 padding-0' : '') + ' "></ul>';
4643
+ var TEMPLATE_MAIN = '<ul class="nav navbar-nav ' + (isVertical ? 'col-md-12 padding-0' : '') + ' " style="float:left"></ul>';
4652
4644
  var options = {};
4653
4645
  try {
4654
4646
  options = JSON.parse(attrs.options);
@@ -98,18 +98,14 @@
98
98
  console.log(complete);
99
99
  });
100
100
  }.bind(this)
101
- }).then(function(data, status, headers, config) {
101
+ }).success(function(data, status, headers, config) {
102
102
  pageScope.cronapi.evalInContext(JSON.stringify(data)).then((result) => {
103
103
  $scope.uploaded = true;
104
104
  $scope.uploading = false;
105
105
  $scope.close();
106
106
  });
107
- }.bind(this)).catch(function(data, status, errorThrown) {
108
- let error = data.error;
109
- if (data && data.data) {
110
- error = data.data.error;
111
- }
112
- this.Notification.error(error);
107
+ }.bind(this)).error(function(data, status, errorThrown) {
108
+ this.Notification.error(data.error);
113
109
  $scope.uploading = false;
114
110
  $scope.close();
115
111
  }.bind(this));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cronapp-framework-js",
3
- "version": "2.8.24",
3
+ "version": "2.8.25",
4
4
  "description": "Javascript library for CronApp's projects",
5
5
  "main": "cronapp.framework.js",
6
6
  "scripts": {
@@ -43,10 +43,10 @@
43
43
  "pace": "HubSpot/pace#v0.7.8",
44
44
  "raphael": "DmitryBaranovskiy/raphael#v2.1.4",
45
45
  "ui-select-infinity": "hyzhak/ui-select-infinity#v0.1.5",
46
- "angular-ui-router": "1.0.29",
46
+ "angular-ui-router": "angular-ui/ui-router#0.2.15",
47
47
  "eonasdan-bootstrap-datetimepicker": "^4.17.49",
48
48
  "natives": "1.1.6",
49
- "angular": "1.8.2",
49
+ "angular": "1.5.9",
50
50
  "angular-ui-bootstrap": "0.13.0",
51
51
  "angular-chart.js": "1.1.1",
52
52
  "angular-cookies": "1.5.8",
@@ -54,21 +54,21 @@
54
54
  "angular-i18n": "1.4.5",
55
55
  "angular-resource": "1.3.15",
56
56
  "angular-sanitize": "1.3.15",
57
- "angular-translate": "2.19.0",
58
- "angular-translate-handler-log": "2.19.0",
59
- "angular-translate-loader-static-files": "2.19.0",
60
- "angular-translate-storage-cookie": "2.19.0",
61
- "angular-translate-storage-local": "2.19.0",
57
+ "angular-translate": "2.11.1",
58
+ "angular-translate-handler-log": "2.11.1",
59
+ "angular-translate-loader-static-files": "2.11.1",
60
+ "angular-translate-storage-cookie": "2.11.1",
61
+ "angular-translate-storage-local": "2.11.1",
62
62
  "angular-ui-notification": "0.3.6",
63
63
  "ui-select": "0.18.1",
64
- "bootstrap": "3.4.1",
64
+ "bootstrap": "3.3.4",
65
65
  "chart.js": "2.7.0",
66
66
  "cpf_cnpj": "0.2.0",
67
67
  "font-awesome": "4.4.0",
68
68
  "jquery": "3.5.1",
69
69
  "justgage": "1.3.5",
70
- "moment": "2.29.1",
71
- "moment-timezone": "0.5.33",
70
+ "moment": "2.9.0",
71
+ "moment-timezone": "0.4.0",
72
72
  "ng-file-upload": "12.2.13"
73
73
  }
74
74
  }
@@ -1,15 +0,0 @@
1
- .font-size-20 {
2
- font-size: 20px;
3
- }
4
-
5
- .font-size-25 {
6
- font-size: 25px;
7
- }
8
-
9
- .font-size-47 {
10
- font-size: 47px;
11
- }
12
-
13
- .font-size-30 {
14
- font-size: 30px;
15
- }
@@ -1,15 +0,0 @@
1
- .object-fit-contain {
2
- object-fit: contain;
3
- }
4
-
5
- .object-fit-cover {
6
- object-fit: cover;
7
- }
8
-
9
- .object-fit-fill {
10
- object-fit: fill;
11
- }
12
-
13
- .object-fit-none {
14
- object-fit: none;
15
- }
@@ -1 +0,0 @@
1
- .font-size-20{font-size:20px}.font-size-25{font-size:25px}.font-size-47{font-size:47px}.font-size-30{font-size:30px}
@@ -1 +0,0 @@
1
- .object-fit-contain{object-fit:contain}.object-fit-cover{object-fit:cover}.object-fit-fill{object-fit:fill}.object-fit-none{object-fit:none}