@awes-io/ui 2.132.0 → 2.132.2

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,28 @@
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.132.2](https://github.com/awes-io/client/compare/@awes-io/ui@2.132.1...@awes-io/ui@2.132.2) (2025-07-30)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **aw-address:** filter unused address components ([8aaf228](https://github.com/awes-io/client/commit/8aaf22813877f4f241ebae55f98309c4c0ff2429))
12
+
13
+
14
+
15
+
16
+
17
+ ## [2.132.1](https://github.com/awes-io/client/compare/@awes-io/ui@2.132.0...@awes-io/ui@2.132.1) (2025-06-24)
18
+
19
+
20
+ ### Bug Fixes
21
+
22
+ * animate all buttons on action ([dc76915](https://github.com/awes-io/client/commit/dc76915a1701f68d263857efff3c0568bc427142))
23
+
24
+
25
+
26
+
27
+
6
28
  # [2.132.0](https://github.com/awes-io/client/compare/@awes-io/ui@2.131.0...@awes-io/ui@2.132.0) (2025-06-24)
7
29
 
8
30
 
@@ -265,9 +265,9 @@
265
265
  --btn-min-width: var(--btn-size);
266
266
  flex-shrink: 0;
267
267
 
268
- &:active {
268
+ /* &:active {
269
269
  transform: none;
270
- }
270
+ } */
271
271
  }
272
272
 
273
273
  &--loading {
@@ -28,6 +28,19 @@ import axios from 'axios'
28
28
  import { pathOr, pick } from 'rambdax'
29
29
  import gmMixin from '@AwMixins/google-maps'
30
30
 
31
+ const FILTER_TYPES = ['political', 'intersection']
32
+ const FILTER_PREFIXES = ['sublocality_level_']
33
+
34
+ const getType = (types) => {
35
+ return (
36
+ types.filter(
37
+ (type) =>
38
+ !FILTER_TYPES.includes(type) &&
39
+ !FILTER_PREFIXES.some((prefix) => type.startsWith(prefix))
40
+ )[0] || types[0]
41
+ )
42
+ }
43
+
31
44
  export default {
32
45
  name: 'AwAddress',
33
46
 
@@ -73,9 +86,11 @@ export default {
73
86
  this.$refs.select.searchPhrase = ''
74
87
  }
75
88
  this._resetSearch()
76
- this._formatAddressResponse(details, place).then((result) => {
77
- this.$emit('input', result)
78
- })
89
+ this._formatAddressResponse(details, place).then(
90
+ (result) => {
91
+ this.$emit('input', result)
92
+ }
93
+ )
79
94
  }
80
95
  )
81
96
  }
@@ -153,12 +168,16 @@ export default {
153
168
  const response = {
154
169
  description: details.formatted_address || place.description,
155
170
  main: pathOr('', 'structured_formatting.main_text', place),
156
- secondary: pathOr('', 'structured_formatting.secondary_text', place)
171
+ secondary: pathOr(
172
+ '',
173
+ 'structured_formatting.secondary_text',
174
+ place
175
+ )
157
176
  }
158
177
 
159
178
  details.address_components.forEach(
160
179
  ({ long_name, short_name, types }) => {
161
- const type = types[0]
180
+ const type = getType(types)
162
181
 
163
182
  response[type] = long_name
164
183
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@awes-io/ui",
3
- "version": "2.132.0",
3
+ "version": "2.132.2",
4
4
  "description": "User Interface (UI) components",
5
5
  "keywords": [
6
6
  "ui",
@@ -114,5 +114,5 @@
114
114
  "rollup-plugin-visualizer": "^2.6.0",
115
115
  "rollup-plugin-vue": "^5.0.1"
116
116
  },
117
- "gitHead": "642980f67d06500661147faf8d998530a9071882"
117
+ "gitHead": "c3ae74a2451e07b3a3798f285cd1aee0e7bffc69"
118
118
  }