@itfin/components 1.0.20 → 1.0.21

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.0.20",
3
+ "version": "1.0.21",
4
4
  "main": "dist/itfin-components.umd.js",
5
5
  "unpkg": "dist/itfin-components.common.js",
6
6
  "author": "Vitalii Savchuk <esvit666@gmail.com>",
@@ -24,18 +24,17 @@ $link-color: #0B314F;
24
24
  $input-btn-focus-width: .125rem;
25
25
 
26
26
  $input-bg: #f3f3f3;
27
- $input-border-color: #f3f3f3;
27
+ $input-border-color: rgba(#000, .08);
28
28
  $input-border-radius: 10px;
29
29
  $input-font-family: 'Fira Mono', monospace;
30
30
 
31
- $input-focus-bg: #f9f6e8;
32
- $input-focus-border-color: #f9f6e8;
33
-
34
- $input-focus-box-shadow: none;
31
+ $input-focus-bg: #fff;
32
+ $input-focus-border-color: #fff;
35
33
 
36
34
  $form-label-margin-bottom: .1rem;
37
35
  $input-focus-border: rgb(11 49 79 / 25%);
38
36
 
37
+ $form-check-input-border: 1px solid rgba(#000, .08);
39
38
  $form-switch-focus-color: tint-color($primary, 50%);
40
39
  $dropdown-link-hover-bg: tint-color($primary, 50%);
41
40
  $dropdown-link-active-bg: tint-color($primary, 70%);
@@ -3,7 +3,8 @@
3
3
  opacity: 0;
4
4
  transform: translateZ(0);
5
5
  transition: opacity .1s;
6
- right: 1rem;
6
+ right: 0.75rem;
7
+ position: absolute;
7
8
  mix-blend-mode: normal;
8
9
  width: 1rem;
9
10
  height: 1rem;
@@ -12,6 +12,9 @@
12
12
  @import '../../assets/scss/variables';
13
13
 
14
14
  .itf-checkbox {
15
+ .form-check-input, .form-check-label {
16
+ cursor: pointer;
17
+ }
15
18
  &__large {
16
19
  padding-left: $form-check-padding-start * 2;
17
20
  min-height: 2.5rem;
@@ -24,6 +27,7 @@
24
27
  width: $form-check-input-width * 2;
25
28
  height: $form-check-input-width * 2;
26
29
  margin-left: -$form-check-padding-start * 2;
30
+ border-radius: 0.75rem;
27
31
  }
28
32
  &.form-switch {
29
33
  padding-left: $form-switch-padding-start * 2;
@@ -31,6 +35,7 @@
31
35
  .form-check-input {
32
36
  width: $form-switch-width * 2;
33
37
  margin-left: -$form-switch-padding-start * 2;
38
+ border-radius: 100px;
34
39
  }
35
40
  }
36
41
  }
@@ -43,6 +48,7 @@
43
48
  width: $form-check-input-width * 1.5;
44
49
  height: $form-check-input-width * 1.5;
45
50
  margin-left: -$form-check-padding-start * 1.5;
51
+ border-radius: 0.5rem;
46
52
  }
47
53
  &.form-switch {
48
54
  padding-left: $form-switch-padding-start * 1.5;
@@ -50,6 +56,7 @@
50
56
  .form-check-input {
51
57
  width: $form-switch-width * 1.5;
52
58
  margin-left: -$form-switch-padding-start * 1.5;
59
+ border-radius: 100px;
53
60
  }
54
61
  }
55
62
  }
@@ -40,7 +40,7 @@
40
40
  :aria-label="`Deselect ${getOptionLabel(option)}`"
41
41
  @click="deselect(option)"
42
42
  >
43
- <deselect />
43
+ <itf-icon name="close" />
44
44
  </itf-button>
45
45
  </span>
46
46
  </slot>
@@ -66,17 +66,18 @@
66
66
  aria-label="Clear Selected"
67
67
  @click="clearSelection"
68
68
  >
69
- <deselect />
69
+ <itf-icon name="close" />
70
70
  </itf-button>
71
71
 
72
72
  <slot name="open-indicator" v-bind="scope.openIndicator">
73
73
  <itf-button
74
+ tabindex="-1"
74
75
  small
75
76
  icon
76
77
  v-if="!noDrop && !mutableLoading && !disabled"
77
78
  v-bind="scope.openIndicator.attributes"
78
79
  >
79
- <open-indicator />
80
+ <itf-icon name="chevron_down" />
80
81
  </itf-button>
81
82
  </slot>
82
83
 
@@ -223,8 +224,7 @@
223
224
  import pointerScroll from '../../mixins/pointerScroll';
224
225
  import typeAheadPointer from '../../mixins/typeAheadPointer';
225
226
  import ajax from '../../mixins/ajax';
226
- import Deselect from './Deselect';
227
- import OpenIndicator from './OpenIndicator';
227
+ import itfIcon from '../icon/Icon';
228
228
  import itfButton from '../button/Button';
229
229
  import appendToBody from '../../directives/appendToBody';
230
230
  import sortAndStringify from '../../helpers/sortAndStringify';
@@ -234,9 +234,8 @@ import uniqueId from '../../helpers/uniqueId';
234
234
  */
235
235
  export default {
236
236
  components: {
237
- Deselect,
238
- OpenIndicator,
239
237
  itfButton,
238
+ itfIcon
240
239
  },
241
240
  directives: { appendToBody },
242
241
  mixins: [pointerScroll, typeAheadPointer, ajax],
@@ -72,7 +72,12 @@ storiesOf('Common', module)
72
72
  {{ selected }}
73
73
 
74
74
  <itf-select
75
- opened
75
+ placeholder="Country"
76
+ :reduce="country => country.code"
77
+ v-model="selected" label="country" :options="countries"></itf-select>
78
+
79
+ <itf-select
80
+ loading
76
81
  placeholder="Country"
77
82
  :reduce="country => country.code"
78
83
  v-model="selected" label="country" :options="countries"></itf-select>
@@ -1,3 +0,0 @@
1
- <template>
2
- <svg height="21" viewBox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"><g fill="none" fill-rule="evenodd" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"><path d="m7.5 7.5 6 6"/><path d="m13.5 7.5-6 6"/></g></svg>
3
- </template>
@@ -1,3 +0,0 @@
1
- <template>
2
- <svg height="21" viewBox="0 0 21 21" width="21" xmlns="http://www.w3.org/2000/svg"><path d="m8.5.5-4 4-4-4" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" transform="translate(6 8)"/></svg>
3
- </template>