@d-mok/quasar-app-extension-quasar-axe 1.0.49 → 1.0.52
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 +1 -1
- package/src/index.js +15 -15
- package/src/puppets/builder/index.ts +6 -0
- package/src/puppets/core/db.ts +1 -0
- package/src/puppets/type.ts +1 -0
package/package.json
CHANGED
package/src/index.js
CHANGED
|
@@ -1,35 +1,35 @@
|
|
|
1
1
|
function extendQuasarConf(conf, prompts) {
|
|
2
2
|
|
|
3
|
-
let boots = ['Interceptor','AutoReg', 'RegComp', 'AutoRoute']
|
|
3
|
+
let boots = ['Interceptor', 'AutoReg', 'RegComp', 'AutoRoute']
|
|
4
4
|
for (let b of boots) {
|
|
5
|
-
conf.boot.push(`~@d-mok/quasar-app-extension-quasar-axe/src/boot/${b}.ts`)
|
|
5
|
+
conf.boot.push(`~@d-mok/quasar-app-extension-quasar-axe/src/boot/${b}.ts`)
|
|
6
6
|
}
|
|
7
7
|
|
|
8
|
-
console.log("[QuasarAxe] Config pushed Boots")
|
|
8
|
+
console.log("[QuasarAxe] Config pushed Boots")
|
|
9
9
|
|
|
10
|
-
conf.build.transpileDependencies.push(/\@d-mok\/quasar-app-extension-quasar-axe[\\/]src/)
|
|
10
|
+
conf.build.transpileDependencies.push(/\@d-mok\/quasar-app-extension-quasar-axe[\\/]src/)
|
|
11
11
|
|
|
12
12
|
|
|
13
|
-
conf.framework.plugins.push('AppVisibility', 'Notify', 'Dialog', 'LoadingBar')
|
|
14
|
-
console.log("[QuasarAxe] Config pushed framework.plugins")
|
|
13
|
+
conf.framework.plugins.push('AppVisibility', 'Notify', 'Dialog', 'LoadingBar')
|
|
14
|
+
console.log("[QuasarAxe] Config pushed framework.plugins")
|
|
15
15
|
|
|
16
16
|
conf.framework.config.loadingBar = {
|
|
17
17
|
position: "top",
|
|
18
18
|
color: "white",
|
|
19
19
|
size: "5px",
|
|
20
20
|
skipHijack: true
|
|
21
|
-
}
|
|
22
|
-
conf.framework.config.notify = {}
|
|
23
|
-
console.log("[QuasarAxe] Config pushed framework.config")
|
|
21
|
+
}
|
|
22
|
+
conf.framework.config.notify = {}
|
|
23
|
+
console.log("[QuasarAxe] Config pushed framework.config")
|
|
24
24
|
|
|
25
|
-
conf.animations.push('fadeIn', 'fadeOut')
|
|
26
|
-
console.log("[QuasarAxe] Config pushed animations")
|
|
25
|
+
conf.animations.push('fadeIn', 'fadeOut')
|
|
26
|
+
console.log("[QuasarAxe] Config pushed animations")
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
|
|
30
30
|
|
|
31
31
|
module.exports = function (api) {
|
|
32
|
-
api.compatibleWith('quasar', '^2.0.0')
|
|
33
|
-
api.compatibleWith('@quasar/app', '^3.0.0')
|
|
34
|
-
api.extendQuasarConf(conf => extendQuasarConf(conf, api.prompts))
|
|
35
|
-
}
|
|
32
|
+
api.compatibleWith('quasar', '^2.0.0')
|
|
33
|
+
api.compatibleWith('@quasar/app', '^3.0.0')
|
|
34
|
+
api.extendQuasarConf(conf => extendQuasarConf(conf, api.prompts))
|
|
35
|
+
}
|
|
@@ -122,6 +122,12 @@ abstract class FilterBuilder<T, R> extends Builder<T, R>{
|
|
|
122
122
|
return this
|
|
123
123
|
}
|
|
124
124
|
|
|
125
|
+
like<K extends keyof R>(key: K, pattern: string): this {
|
|
126
|
+
this.filters.push({ type: 'like', payload: { key, pattern } })
|
|
127
|
+
return this
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
|
|
125
131
|
limit(count: number): this {
|
|
126
132
|
this.filters.push({ type: 'limit', payload: count })
|
|
127
133
|
return this
|
package/src/puppets/core/db.ts
CHANGED
|
@@ -34,6 +34,7 @@ async function sendSingle<R>(q: PromiseLike<PostgrestSingleResponse<R>>): Promis
|
|
|
34
34
|
function parseFilter<R>(q: PostgrestFilterBuilder<R>, filter: Filter<R>): PostgrestFilterBuilder<R> {
|
|
35
35
|
if (filter.type === 'eq') q = q.eq(filter.payload.key, filter.payload.val)
|
|
36
36
|
if (filter.type === 'in') q = q.in(filter.payload.key, filter.payload.vals)
|
|
37
|
+
if (filter.type === 'like') q = q.like(filter.payload.key, filter.payload.pattern)
|
|
37
38
|
return q
|
|
38
39
|
}
|
|
39
40
|
|
package/src/puppets/type.ts
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
export type Filter<R> =
|
|
3
3
|
| { type: 'eq', payload: { key: keyof R, val: any } }
|
|
4
4
|
| { type: 'in', payload: { key: keyof R, vals: any[] } }
|
|
5
|
+
| { type: 'like', payload: { key: keyof R, pattern: string } }
|
|
5
6
|
| { type: 'limit', payload: number }
|
|
6
7
|
| { type: 'order', payload: { key: keyof R, asc: boolean } }
|
|
7
8
|
|