@kigi/components 1.5.10-beta.0 → 1.5.10-beta.1

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kigi/components",
3
- "version": "1.5.10-beta.0",
3
+ "version": "1.5.10-beta.1",
4
4
  "description": "@kigi/components",
5
5
  "main": "src/components/index.ts",
6
6
  "scripts": {
@@ -7,6 +7,7 @@
7
7
  ng-show="$ctrl.ngModel"
8
8
  ng-click="$ctrl.openModal()">
9
9
  <img ng-show="$ctrl.ngModel"
10
+ ng-style="{ 'object-fit': 'contain', 'width': '100%'}"
10
11
  src="{{$ctrl.ngModel}}">
11
12
  </div>
12
13
  <div class="icon-upload-image-crop">
@@ -53,17 +53,19 @@
53
53
  align-items: center;
54
54
 
55
55
  .buttons {
56
- cursor: pointer;
57
56
  width: 100%;
58
57
  display: flex;
59
58
  justify-content: center;
59
+
60
+ a {
61
+ cursor: pointer;
62
+ }
60
63
  }
61
64
 
62
65
  .remove {
63
66
  justify-content: space-around;
64
67
  }
65
68
  }
66
-
67
69
  &:hover {
68
70
  background: #e4e4e4;
69
71
  }
@@ -21,12 +21,12 @@
21
21
  <label ng-show="$ctrl.image"
22
22
  style="font-weight: 500;">Imagem atual</label>
23
23
  <img ng-if="$ctrl.image"
24
- style="width: 50%;"
24
+ style="max-height: 200px;max-width: 400px; object-fit: contain;"
25
25
  class="m-b-24"
26
26
  src="{{$ctrl.image}}"></i>
27
27
 
28
- <label ng-show="$ctrl.image">Clique aqui ou arraste e solte uma imagem para editar</label>
29
- <label ng-show="!$ctrl.image">Clique aqui ou arraste e solte uma imagem para adicionar</label>
28
+ <label ng-show="$ctrl.image">Arraste e solte uma imagem ou clique aqui para editar</label>
29
+ <label ng-show="!$ctrl.image">Arraste e solte uma imagem ou clique aqui para adicionar</label>
30
30
  </div>
31
31
  </div>
32
32
  <div class="relative-content"
@@ -5,6 +5,7 @@
5
5
 
6
6
  .relative-content {
7
7
  position: relative;
8
+ max-height: 400px;
8
9
 
9
10
  .stop-upload {
10
11
  z-index: 1000;
@@ -57,6 +58,7 @@
57
58
  display: none;
58
59
  }
59
60
  .crop-image-original {
61
+ display: block;
60
62
  max-width: 100%;
61
63
  }
62
64
  .image-drap-drop-container {
@@ -129,7 +129,6 @@ class UploadImageCropModalController {
129
129
  response.metadata.name,
130
130
  )
131
131
 
132
- console.log(imageURL)
133
132
  this.$uibModalInstance.close(imageURL)
134
133
  } catch (e) {
135
134
  console.log(e)
package/src/index.ts CHANGED
@@ -33,12 +33,13 @@ const module = angular.module('demo', ['ngLocale', components]).controller('demo
33
33
  ($scope, $timeout, $http, mbgAlert: MbgAlert) => {
34
34
  $scope.imgCrop = 'https://i.pinimg.com/originals/c3/a5/b3/c3a5b332f9716abb1c67da38a12595e8.jpg'
35
35
  $scope.configImgCrop = {
36
- aspectRatio: 1 / 0.75,
36
+ aspectRatio: 16 / 9,
37
37
  minCropBoxWidth: 200,
38
- minCropBoxHeight: 200,
39
- minCanvasHeight: 100,
38
+ minCropBoxHeight: 100,
39
+ minCanvasHeight: 200,
40
40
  minContainerHeight: 100,
41
41
  height: '124px',
42
+ // width: '300px',
42
43
  }
43
44
 
44
45
  $scope.configDocument = {