@itfin/components 1.2.26 → 1.2.28

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": "@itfin/components",
3
- "version": "1.2.26",
3
+ "version": "1.2.28",
4
4
  "author": "Vitalii Savchuk <esvit666@gmail.com>",
5
5
  "scripts": {
6
6
  "serve": "vue-cli-service serve",
@@ -3,6 +3,10 @@
3
3
  @import './dark-theme.scss';
4
4
  @import './scrollbar';
5
5
 
6
+ .form-control {
7
+ min-height: 2.5rem;
8
+ }
9
+
6
10
  .color-project-tnm {
7
11
  color: $project-tnm;
8
12
  }
@@ -89,11 +89,13 @@
89
89
  }
90
90
  </style>
91
91
  <script>
92
- import { Vue, Component, Prop, Inject } from 'vue-property-decorator';
92
+ import {
93
+ Vue, Component, Prop, Inject
94
+ } from 'vue-property-decorator';
93
95
  import { IMask, IMaskComponent } from 'vue-imask';
94
96
  import { DateTime } from 'luxon';
95
- import { debounce } from '../../helpers/debounce';
96
97
  import tippy from 'tippy.js';
98
+ import { debounce } from '../../helpers/debounce';
97
99
  import itfIcon from '../icon/Icon.vue';
98
100
  import itfButton from '../button/Button.vue';
99
101
  import itfDatePickerInline from './DatePickerInline.vue';
@@ -177,7 +179,7 @@ class itfDatePicker extends Vue {
177
179
  return null;
178
180
  }
179
181
  if (this.valueFormat === 'ISO') {
180
- return DateTime.fromISO(this.value);
182
+ return DateTime.fromISO(this.value, { zone: 'UTC' });
181
183
  }
182
184
  return DateTime.fromFormat(this.value, this.valueFormat);
183
185
  }
@@ -5,7 +5,7 @@
5
5
  class="modal-dialog"
6
6
  :class="{[`modal-${size}`]: size, 'modal-fullscreen': fullscreen, 'modal-fullscreen-sm-down': !fullscreen}"
7
7
  >
8
- <div class="modal-content itf-append-context" ref="content">
8
+ <div class="modal-content itf-append-context" ref="content" @click.prevent.stop>
9
9
  <div class="modal-header">
10
10
  <slot name="title">
11
11
  <h5 class="modal-title" :id="modalId">{{title}}</h5>
@@ -62,7 +62,7 @@
62
62
  fill-rule="evenodd"
63
63
  ></path>
64
64
  </svg>
65
- <div class="font-medium">Add more</div>
65
+ <div class="font-medium">{{ addMoreText }}</div>
66
66
  </div>
67
67
  </div>
68
68
 
@@ -140,6 +140,8 @@ class itfAirSelect extends Vue {
140
140
 
141
141
  @Prop({ type: Boolean, default: false }) customRender;
142
142
  @Prop({ type: Boolean, default: false }) customRenderOption;
143
+ // eslint-disable-next-line object-shorthand
144
+ @Prop({ type: String, default: function() { return this.$t('components.addMore'); } }) addMoreText;
143
145
 
144
146
  @Ref('selectRef') selectRef;
145
147
 
@@ -51,6 +51,8 @@
51
51
  white-space: pre-line;
52
52
  visibility: hidden;
53
53
  min-height: 4rem;
54
+ max-height: 75vh; // жалувались, що коли багато тексту,
55
+ // то поле за межі вікна виходить і не зручно
54
56
  }
55
57
  }
56
58
  </style>
@@ -142,7 +142,7 @@ export function dateBeforeValidation (dateCompare, message) {
142
142
  const d1 = DateTime.fromFormat(v, STANDART_DATE_FORMAT).startOf('day');
143
143
  const d2 = DateTime.fromFormat(dateCompare, STANDART_DATE_FORMAT).startOf('day');
144
144
 
145
- return d1 < d2 || (message || $t('validators.dateBefore', { date: formatDate(dateCompare) }));
145
+ return d1 < d2 || (message || $t('components.dateBefore', { date: formatDate(dateCompare) }));
146
146
  };
147
147
  }
148
148
 
@@ -154,7 +154,7 @@ export function dateAfterValidation (dateCompare, message) {
154
154
  const d1 = DateTime.fromFormat(v, STANDART_DATE_FORMAT).startOf('day');
155
155
  const d2 = DateTime.fromFormat(dateCompare, STANDART_DATE_FORMAT).startOf('day');
156
156
 
157
- return d1 > d2 || (message || $t('validators.dateAfter', { date: formatDate(dateCompare) }));
157
+ return d1 > d2 || (message || $t('components.dateAfter', { date: formatDate(dateCompare) }));
158
158
  };
159
159
  }
160
160
 
@@ -166,7 +166,7 @@ export function dateSameOrAfterValidation (dateCompare, message) {
166
166
  const d1 = DateTime.fromFormat(v, STANDART_DATE_FORMAT).startOf('day');
167
167
  const d2 = DateTime.fromFormat(dateCompare, STANDART_DATE_FORMAT).startOf('day');
168
168
 
169
- return d1 >= d2 || (message || $t('validators.dateSameOrAfter', { date: formatDate(dateCompare) }));
169
+ return d1 >= d2 || (message || $t('components.dateSameOrAfter', { date: formatDate(dateCompare) }));
170
170
  };
171
171
  }
172
172
 
@@ -178,6 +178,6 @@ export function dateSameOrBeforeValidation (dateCompare, message) {
178
178
  const d1 = DateTime.fromFormat(v, STANDART_DATE_FORMAT).startOf('day');
179
179
  const d2 = DateTime.fromFormat(dateCompare, STANDART_DATE_FORMAT).startOf('day');
180
180
 
181
- return d1 <= d2 || (message || $t('validators.dateSameOrBefore', { date: formatDate(dateCompare) }));
181
+ return d1 <= d2 || (message || $t('components.dateSameOrBefore', { date: formatDate(dateCompare) }));
182
182
  };
183
183
  }