@d-mok/quasar-app-extension-quasar-axe 2.1.93 → 2.1.95

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": "@d-mok/quasar-app-extension-quasar-axe",
3
- "version": "2.1.93",
3
+ "version": "2.1.95",
4
4
  "description": "A Quasar App Extension",
5
5
  "author": "d-mok <49301824+d-mok@users.noreply.github.com>",
6
6
  "license": "MIT",
@@ -27,7 +27,7 @@
27
27
  "lodash": "^4.17.21",
28
28
  "mime-types": "^2.1.35",
29
29
  "papaparse": "^5.4.1",
30
- "sapphire-js": "^2.1.8",
30
+ "sapphire-js": "^2.1.9",
31
31
  "sortablejs": "^1.15.0",
32
32
  "vuedraggable": "^4.1.0"
33
33
  },
@@ -18,23 +18,22 @@ import { ref } from 'vue'
18
18
 
19
19
  let modelValue = defineModel<string>({ required: true })
20
20
 
21
- const props = defineProps<{
21
+ const { autocomplete, immediate = false } = defineProps<{
22
22
  autocomplete: string[]
23
+ immediate?: boolean
23
24
  }>()
24
25
 
25
- // if (!modelValue.value) modelValue.value = ''
26
-
27
26
  let options = ref<string[]>([])
28
27
 
29
28
  function filterFn(val: any, update: any) {
30
29
  if (!val) val = modelValue.value
31
30
  update(() => {
32
- if (!val) {
31
+ if (!immediate && !val) {
33
32
  options.value = []
34
33
  return
35
34
  }
36
35
  const needle = val.toLowerCase()
37
- options.value = props.autocomplete.filter(
36
+ options.value = autocomplete.filter(
38
37
  v => v.toLowerCase().indexOf(needle) > -1
39
38
  )
40
39
  })