mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-08 17:30:09 +02:00
XFA - Handle shorcut in SOM expression (issue #13994)
This commit is contained in:
parent
8a79f13e5a
commit
c5841b3794
3 changed files with 17 additions and 1 deletions
|
@ -15,6 +15,7 @@
|
||||||
|
|
||||||
import {
|
import {
|
||||||
$appendChild,
|
$appendChild,
|
||||||
|
$getChildren,
|
||||||
$getChildrenByClass,
|
$getChildrenByClass,
|
||||||
$getChildrenByName,
|
$getChildrenByName,
|
||||||
$getParent,
|
$getParent,
|
||||||
|
@ -37,7 +38,12 @@ const operators = {
|
||||||
};
|
};
|
||||||
|
|
||||||
const shortcuts = new Map([
|
const shortcuts = new Map([
|
||||||
["$data", (root, current) => root.datasets.data],
|
["$data", (root, current) => (root.datasets ? root.datasets.data : root)],
|
||||||
|
[
|
||||||
|
"$record",
|
||||||
|
(root, current) =>
|
||||||
|
(root.datasets ? root.datasets.data : root)[$getChildren]()[0],
|
||||||
|
],
|
||||||
["$template", (root, current) => root.template],
|
["$template", (root, current) => root.template],
|
||||||
["$connectionSet", (root, current) => root.connectionSet],
|
["$connectionSet", (root, current) => root.connectionSet],
|
||||||
["$form", (root, current) => root.form],
|
["$form", (root, current) => root.form],
|
||||||
|
|
1
test/pdfs/xfa_issue13994.pdf.link
Normal file
1
test/pdfs/xfa_issue13994.pdf.link
Normal file
|
@ -0,0 +1 @@
|
||||||
|
https://github.com/mozilla/pdf.js/files/7138335/Form_MGT-14-try-1.pdf
|
|
@ -1277,6 +1277,15 @@
|
||||||
"enableXfa": true,
|
"enableXfa": true,
|
||||||
"type": "eq"
|
"type": "eq"
|
||||||
},
|
},
|
||||||
|
{ "id": "xfa_issue13994",
|
||||||
|
"file": "pdfs/xfa_issue13994.pdf",
|
||||||
|
"md5": "787ad7cfbb822bb4f80e2243305c9f0c",
|
||||||
|
"link": true,
|
||||||
|
"rounds": 1,
|
||||||
|
"lastPage": 1,
|
||||||
|
"enableXfa": true,
|
||||||
|
"type": "eq"
|
||||||
|
},
|
||||||
{ "id": "xfa_issue13855",
|
{ "id": "xfa_issue13855",
|
||||||
"file": "pdfs/xfa_issue13855.pdf",
|
"file": "pdfs/xfa_issue13855.pdf",
|
||||||
"md5": "0aaaf62ff979c7837c2c63df44456238",
|
"md5": "0aaaf62ff979c7837c2c63df44456238",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue