-
Notifications
You must be signed in to change notification settings - Fork 1
/
create link using Adobe Acrobat Pro.js
57 lines (54 loc) · 1.24 KB
/
create link using Adobe Acrobat Pro.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
var pageNumber = this.pageNum;
var pdfName = this.documentFileName;
var obsidianLink =
'```pdf\r{"url": "/PDF files/' +
pdfName +
'",\r"page": [' +
pageNumber +
']}\n```';
var dialog1 = {
initialize: function (dialog) {
dialog.load({ link: obsidianLink });
},
description: {
name: 'link for Obsidian link', // Dialog box title
align_children: 'align_left',
width: 350,
height: 200,
elements: [
{
type: 'cluster',
name: 'Obsidian Link: ',
align_children: 'align_left',
elements: [
{
type: 'view',
align_children: 'align_row',
elements: [
{
type: 'static_text',
name: 'link : ',
},
{
//the item_id should be a four character string
item_id: 'link',
type: 'edit_text',
alignment: 'align_fill',
multiline: true,
width: 300,
height: 80,
},
],
},
],
},
{
alignment: 'align_right',
type: 'ok_cancel',
ok_name: 'Ok',
cancel_name: 'Cancel',
},
],
},
};
app.execDialog(dialog1);