@awes-io/ui 2.60.0 → 2.61.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/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,33 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [2.61.1](https://github.com/awes-io/client/compare/@awes-io/ui@2.61.0...@awes-io/ui@2.61.1) (2023-01-11)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* **aw-bottom-bar:** action button listeners application fixed ([bfa4057](https://github.com/awes-io/client/commit/bfa4057da6f7c9a5c3393b0a2483ba2bd6c5f97b))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
# [2.61.0](https://github.com/awes-io/client/compare/@awes-io/ui@2.60.0...@awes-io/ui@2.61.0) (2022-12-29)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### Bug Fixes
|
|
21
|
+
|
|
22
|
+
* useless component removed ([b69fe35](https://github.com/awes-io/client/commit/b69fe35d2df567d3d79cb2cc5d8e80fb64ee9ec6))
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
### Features
|
|
26
|
+
|
|
27
|
+
* aw-select tuning ([a2d55ea](https://github.com/awes-io/client/commit/a2d55ea1ccc409232c61b95ad642e2f90669e830))
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
6
33
|
# [2.60.0](https://github.com/awes-io/client/compare/@awes-io/ui@2.59.2...@awes-io/ui@2.60.0) (2022-12-19)
|
|
7
34
|
|
|
8
35
|
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
:placeholder="_placeholder"
|
|
34
34
|
:clearable="clearable && !_isEmpty"
|
|
35
35
|
:is-opened="isOpened"
|
|
36
|
-
caret
|
|
36
|
+
:caret="isCaretVisible"
|
|
37
37
|
:class="{
|
|
38
38
|
'is-filled': searchable && isOpened,
|
|
39
39
|
'not-searchable': !searchable
|
|
@@ -61,6 +61,10 @@
|
|
|
61
61
|
v-bind="{ value: inputValue }"
|
|
62
62
|
></slot>
|
|
63
63
|
</template>
|
|
64
|
+
|
|
65
|
+
<template #caret="data">
|
|
66
|
+
<slot name="caret" v-bind="data" />
|
|
67
|
+
</template>
|
|
64
68
|
</AwSelectFakeInput>
|
|
65
69
|
<AwSelectInput
|
|
66
70
|
v-else
|
|
@@ -71,7 +75,7 @@
|
|
|
71
75
|
:readonly="!searchable"
|
|
72
76
|
:clearable="clearable && !_isEmpty"
|
|
73
77
|
:is-opened="isOpened"
|
|
74
|
-
caret
|
|
78
|
+
:caret="isCaretVisible"
|
|
75
79
|
:class="{
|
|
76
80
|
'is-filled': searchable && isOpened,
|
|
77
81
|
'not-searchable': !searchable
|
|
@@ -102,6 +106,10 @@
|
|
|
102
106
|
v-bind="{ value: inputValue }"
|
|
103
107
|
></slot>
|
|
104
108
|
</template>
|
|
109
|
+
|
|
110
|
+
<template #caret="data">
|
|
111
|
+
<slot name="caret" v-bind="data" />
|
|
112
|
+
</template>
|
|
105
113
|
</AwSelectInput>
|
|
106
114
|
</slot>
|
|
107
115
|
|
|
@@ -150,6 +158,10 @@
|
|
|
150
158
|
}"
|
|
151
159
|
></slot>
|
|
152
160
|
</template>
|
|
161
|
+
|
|
162
|
+
<template #caret="data">
|
|
163
|
+
<slot name="caret" v-bind="data" />
|
|
164
|
+
</template>
|
|
153
165
|
</AwSelectInput>
|
|
154
166
|
</div>
|
|
155
167
|
</slot>
|
|
@@ -230,7 +242,7 @@
|
|
|
230
242
|
</template>
|
|
231
243
|
|
|
232
244
|
<script>
|
|
233
|
-
import { path, pathOr, isNil, equals } from 'rambdax'
|
|
245
|
+
import { path, pathOr, isNil, equals, isType } from 'rambdax'
|
|
234
246
|
import { createPopper } from '@popperjs/core'
|
|
235
247
|
import { disableBodyScroll, enableBodyScroll } from 'body-scroll-lock'
|
|
236
248
|
import CancelToken from 'axios/lib/cancel/CancelToken'
|
|
@@ -339,6 +351,21 @@ export default {
|
|
|
339
351
|
return 0
|
|
340
352
|
}
|
|
341
353
|
}
|
|
354
|
+
},
|
|
355
|
+
|
|
356
|
+
desktopFrom: {
|
|
357
|
+
type: String,
|
|
358
|
+
default: 'md'
|
|
359
|
+
},
|
|
360
|
+
|
|
361
|
+
isCaret: {
|
|
362
|
+
type: [Boolean, Function],
|
|
363
|
+
default: true
|
|
364
|
+
},
|
|
365
|
+
|
|
366
|
+
isNotFound: {
|
|
367
|
+
type: Boolean,
|
|
368
|
+
default: null
|
|
342
369
|
}
|
|
343
370
|
},
|
|
344
371
|
|
|
@@ -483,23 +510,32 @@ export default {
|
|
|
483
510
|
},
|
|
484
511
|
|
|
485
512
|
_showNotFound() {
|
|
513
|
+
if (this.isNotFound !== null) return this.isNotFound
|
|
514
|
+
|
|
486
515
|
return this._isAjax
|
|
487
516
|
? !this.selectOptions.length && !this.isLoading
|
|
488
517
|
: this._searchPhraseLength && !this.optionsList.length
|
|
489
518
|
},
|
|
490
519
|
|
|
491
520
|
isMobile() {
|
|
492
|
-
return !pathOr(true,
|
|
521
|
+
return !pathOr(true, this.desktopFrom, this.$screen)
|
|
493
522
|
},
|
|
494
523
|
|
|
495
524
|
isMobileOpened() {
|
|
496
525
|
return this.isOpened && this.isMobile
|
|
497
526
|
},
|
|
498
527
|
|
|
528
|
+
isCaretVisible() {
|
|
529
|
+
return isType('Function', this.isCaret)
|
|
530
|
+
? this.isCaret(this.optionsList)
|
|
531
|
+
: !!this.isCaret
|
|
532
|
+
},
|
|
533
|
+
|
|
499
534
|
_inputSlot() {
|
|
500
535
|
return {
|
|
501
536
|
option: this.value,
|
|
502
537
|
optionLabel: this._selectedLabel,
|
|
538
|
+
isMobile: this.isMobile,
|
|
503
539
|
isOpened: this.isOpened,
|
|
504
540
|
isLoading: this.isLoading,
|
|
505
541
|
applySearch: this.applySearch,
|
|
@@ -550,6 +586,8 @@ export default {
|
|
|
550
586
|
}
|
|
551
587
|
|
|
552
588
|
this.$nextTick(this._focusInput)
|
|
589
|
+
|
|
590
|
+
this.$emit('open', { target: this })
|
|
553
591
|
} else {
|
|
554
592
|
if (this._isAjax && this._searchPhraseLength) {
|
|
555
593
|
this.searchPhrase = ''
|
|
@@ -558,6 +596,8 @@ export default {
|
|
|
558
596
|
this.isSearching = false
|
|
559
597
|
this._toggleOutsideHandler(false)
|
|
560
598
|
this.cancelRequest()
|
|
599
|
+
|
|
600
|
+
this.$emit('close', { target: this })
|
|
561
601
|
}
|
|
562
602
|
},
|
|
563
603
|
|
|
@@ -786,6 +826,8 @@ export default {
|
|
|
786
826
|
} else if (input) {
|
|
787
827
|
input.focus()
|
|
788
828
|
}
|
|
829
|
+
|
|
830
|
+
this.$emit('focus', { target: this })
|
|
789
831
|
} catch (e) {
|
|
790
832
|
console.log(e)
|
|
791
833
|
}
|
|
@@ -59,21 +59,23 @@
|
|
|
59
59
|
<AwIconSystemMono name="close" />
|
|
60
60
|
</AwButton>
|
|
61
61
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
62
|
+
<slot name="caret" :is-opened="isOpened">
|
|
63
|
+
<!-- caret and loading -->
|
|
64
|
+
<AwButton
|
|
65
|
+
v-if="caret"
|
|
66
|
+
:size="$attrs.size || 'md'"
|
|
67
|
+
tabindex="-1"
|
|
68
|
+
theme="icon"
|
|
69
|
+
class="h-full"
|
|
70
|
+
@click="$emit('caret')"
|
|
71
|
+
>
|
|
72
|
+
<AwIconSystemMono
|
|
73
|
+
name="triangle"
|
|
74
|
+
class="transition-200"
|
|
75
|
+
:class="{ 'rotate-180': isOpened }"
|
|
76
|
+
/>
|
|
77
|
+
</AwButton>
|
|
78
|
+
</slot>
|
|
77
79
|
</slot>
|
|
78
80
|
</span>
|
|
79
81
|
</span>
|
|
@@ -23,21 +23,23 @@
|
|
|
23
23
|
<AwIconSystemMono name="close" />
|
|
24
24
|
</AwButton>
|
|
25
25
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
26
|
+
<slot name="caret" :is-opened="isOpened">
|
|
27
|
+
<!-- caret and loading -->
|
|
28
|
+
<AwButton
|
|
29
|
+
v-if="caret"
|
|
30
|
+
:size="$attrs.size || 'md'"
|
|
31
|
+
tabindex="-1"
|
|
32
|
+
theme="icon"
|
|
33
|
+
class="h-full"
|
|
34
|
+
@click="$emit('caret')"
|
|
35
|
+
>
|
|
36
|
+
<AwIconSystemMono
|
|
37
|
+
name="triangle"
|
|
38
|
+
class="transition-200"
|
|
39
|
+
:class="{ 'rotate-180': isOpened }"
|
|
40
|
+
/>
|
|
41
|
+
</AwButton>
|
|
42
|
+
</slot>
|
|
41
43
|
</template>
|
|
42
44
|
</AwInput>
|
|
43
45
|
</template>
|
|
@@ -72,12 +72,12 @@ export default {
|
|
|
72
72
|
|
|
73
73
|
let result = { ...button, hideText: true }
|
|
74
74
|
|
|
75
|
-
if (!button.href
|
|
75
|
+
if (!button.href && !button.listeners?.click) {
|
|
76
76
|
result = {
|
|
77
77
|
...button,
|
|
78
78
|
listeners: {
|
|
79
79
|
...button.listeners,
|
|
80
|
-
click: this.$root.$emit(
|
|
80
|
+
click: () => this.$root.$emit(
|
|
81
81
|
'awes-io::bottom-bar-action:click'
|
|
82
82
|
)
|
|
83
83
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@awes-io/ui",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.61.1",
|
|
4
4
|
"description": "User Interface (UI) components",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ui",
|
|
@@ -122,5 +122,5 @@
|
|
|
122
122
|
"vue-template-compiler": "^2.6.10",
|
|
123
123
|
"webfonts-generator": "^0.4.0"
|
|
124
124
|
},
|
|
125
|
-
"gitHead": "
|
|
125
|
+
"gitHead": "7538abc47c20e50e20dcb1bfb33e29b2bfdca1ae"
|
|
126
126
|
}
|