@operato/app 10.29.47 → 10.29.49
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 +17 -0
- package/dist/src/selector/ox-selector-resource-object.js +13 -4
- package/dist/src/selector/ox-selector-resource-object.js.map +1 -1
- package/dist/test/selector-search-goes-to-the-list.test.d.ts +1 -0
- package/dist/test/selector-search-goes-to-the-list.test.js +31 -0
- package/dist/test/selector-search-goes-to-the-list.test.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +12 -12
- package/test/selector-search-goes-to-the-list.test.ts +34 -0
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@operato/app",
|
|
3
3
|
"description": "WebApplication production supporting components following open-wc recommendations",
|
|
4
4
|
"author": "heartyoh",
|
|
5
|
-
"version": "10.29.
|
|
5
|
+
"version": "10.29.49",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "dist/src/index.js",
|
|
8
8
|
"module": "dist/src/index.js",
|
|
@@ -148,18 +148,18 @@
|
|
|
148
148
|
"@graphql-tools/delegate": "^10.0.1",
|
|
149
149
|
"@graphql-tools/wrap": "^10.0.0",
|
|
150
150
|
"@material/web": "^2.0.0",
|
|
151
|
-
"@operato/attachment": "^10.29.
|
|
152
|
-
"@operato/data-grist": "^10.29.
|
|
153
|
-
"@operato/font": "^10.29.
|
|
154
|
-
"@operato/form": "^10.29.
|
|
155
|
-
"@operato/graphql": "^10.29.
|
|
151
|
+
"@operato/attachment": "^10.29.49",
|
|
152
|
+
"@operato/data-grist": "^10.29.49",
|
|
153
|
+
"@operato/font": "^10.29.49",
|
|
154
|
+
"@operato/form": "^10.29.49",
|
|
155
|
+
"@operato/graphql": "^10.29.49",
|
|
156
156
|
"@operato/i18n": "^10.29.27",
|
|
157
|
-
"@operato/input": "^10.29.
|
|
158
|
-
"@operato/layout": "^10.29.
|
|
159
|
-
"@operato/property-editor": "^10.29.
|
|
160
|
-
"@operato/shell": "^10.29.
|
|
157
|
+
"@operato/input": "^10.29.49",
|
|
158
|
+
"@operato/layout": "^10.29.49",
|
|
159
|
+
"@operato/property-editor": "^10.29.49",
|
|
160
|
+
"@operato/shell": "^10.29.49",
|
|
161
161
|
"@operato/styles": "^10.29.30",
|
|
162
|
-
"@operato/utils": "^10.29.
|
|
162
|
+
"@operato/utils": "^10.29.49",
|
|
163
163
|
"cm6-graphql": "^0.0.14",
|
|
164
164
|
"codemirror": "^6.0.1",
|
|
165
165
|
"cronstrue": "^2.2.0",
|
|
@@ -200,5 +200,5 @@
|
|
|
200
200
|
"prettier --write"
|
|
201
201
|
]
|
|
202
202
|
},
|
|
203
|
-
"gitHead": "
|
|
203
|
+
"gitHead": "38fba85b1fa1bc1438086973dfe9ec9f6ec53879"
|
|
204
204
|
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { expect } from '@open-wc/testing'
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* The reference picker's search reaches the list.
|
|
5
|
+
*
|
|
6
|
+
* The popup's title bar has a search box. Its term used to become one `search` filter per column marked
|
|
7
|
+
* `filter: 'search'`; a picker whose columns marked none - an Office deposit or contract picker - sent nothing, and the
|
|
8
|
+
* list came back whole while the box held the typing. The picker's grid now runs in `term` mode and the term goes to the
|
|
9
|
+
* list as its `search`, which the list matches on the fields it declares searchable.
|
|
10
|
+
*
|
|
11
|
+
* Read from the source, as selector-confirm-keeps-value does: the component pulls the GraphQL client in at load.
|
|
12
|
+
*/
|
|
13
|
+
describe('reference picker · the search term goes to the list', () => {
|
|
14
|
+
let source: string
|
|
15
|
+
|
|
16
|
+
before(async () => {
|
|
17
|
+
const response = await fetch('/src/selector/ox-selector-resource-object.ts')
|
|
18
|
+
expect(response.ok).to.be.true
|
|
19
|
+
source = await response.text()
|
|
20
|
+
})
|
|
21
|
+
|
|
22
|
+
it('runs its grid in term mode', () => {
|
|
23
|
+
const grist = source.slice(source.indexOf('<ox-grist'), source.indexOf('>', source.indexOf('<ox-grist')))
|
|
24
|
+
expect(grist).to.include('search-mode="term"')
|
|
25
|
+
})
|
|
26
|
+
|
|
27
|
+
it('sends the term as the list search, and only when there is one', () => {
|
|
28
|
+
const handler = source.slice(source.indexOf(' fetchHandler: FetchHandler'), source.indexOf(' willUpdate('))
|
|
29
|
+
expect(handler).to.include('inherited, search })')
|
|
30
|
+
expect(handler).to.include("${term ? ', $search: String' : ''}")
|
|
31
|
+
expect(handler).to.include("${term ? ', search: $search' : ''}")
|
|
32
|
+
expect(handler).to.include('...(term ? { search: term } : {})')
|
|
33
|
+
})
|
|
34
|
+
})
|