Skip to content

Commit

Permalink
update to version v1.2.4
Browse files Browse the repository at this point in the history
V1.2.4
editor button
Fix: linktext is not shown when popup is chosen. #12
New: default values in the config.(save it once after upgrade)
Improved: filename as default linktext.  #11

Content plugin
New: url parameters for page. #10
New: url parameters for search. #10
Update: PDFjs to 2.10.337
  • Loading branch information
Tazzios committed Oct 2, 2021
1 parent b1fa7df commit a164781
Show file tree
Hide file tree
Showing 136 changed files with 1,075 additions and 475 deletions.
10 changes: 10 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,14 @@
V1.2.4
editor button
Fix: linktext is not shown when popup is chosen. #12
New: default values in the config.(save it once after upgrade)
Improved: filename as default linktext. #11

Content plugin
New: url parameters for page. #10
New: url parameters for search. #10
Update: PDFjs to 2.10.337

V1.2.0
New: We have an editor button!
Improved: check if jdownloads exist.
Expand Down
12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ You also can use custom fields from articles in a article. Set 'Show label' to h
You can create this custom field for in article or jdownloads. Note, You can not use the jdownloads custom field for in an article. Set 'Show label' to hide when creating a custom field for article.

### Optional parameters
### Optional tagparameters

Select viewer. Show the full pdf or only one page as an image.
>viewer=[pdfjs|pdfimage]
Expand Down Expand Up @@ -90,6 +90,16 @@ Use double qoutes around the linktext if it contains a space.
With embed you can also use % for width
>width=80%
### Optional urlparameters

If you want to link to an page with a pdf embedded you can set give following parameters to open a specific page.

>?page=[integer]
>?search=[keyword1]%20[keyword2]
These do not work with the pdfimage viewer else everone cloud access avery page of the pdf file.

## Make pdf 'searchable'
Create a custom text field (with large pdfs you maybe need multiple fields) copy the text from the pdf in the textfield you can now search for the text with smart search.

Expand Down
15 changes: 15 additions & 0 deletions content_plugin/assets/pdfjs/web/custom.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@


add to viewer:

class hidden to
open and bookmarks buttons


remove form viewer.js:

"
if (origin !== viewerOrigin && protocol !== "blob:") {
throw new Error("file origin does not match viewer's");
}
"
39 changes: 25 additions & 14 deletions content_plugin/assets/pdfjs/web/debugger.js
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ var StepperManager = (function StepperManagerClosure() {
},
selectStepper: function selectStepper(pageIndex, selectPanel) {
let i;
pageIndex = pageIndex | 0;
pageIndex |= 0;
if (selectPanel) {
this.manager.selectPanel(this);
}
Expand Down Expand Up @@ -357,27 +357,38 @@ const Stepper = (function StepperClosure() {
let decArgs = args;
if (fn === "showText") {
const glyphs = args[0];
const newArgs = [];
let str = [];
const charCodeRow = c("tr");
const fontCharRow = c("tr");
const unicodeRow = c("tr");
for (let j = 0; j < glyphs.length; j++) {
const glyph = glyphs[j];
if (typeof glyph === "object" && glyph !== null) {
str.push(glyph.fontChar);
charCodeRow.appendChild(c("td", glyph.originalCharCode));
fontCharRow.appendChild(c("td", glyph.fontChar));
unicodeRow.appendChild(c("td", glyph.unicode));
} else {
if (str.length > 0) {
newArgs.push(str.join(""));
str = [];
}
newArgs.push(glyph); // null or number
// null or number
const advanceEl = c("td", glyph);
advanceEl.classList.add("advance");
charCodeRow.appendChild(advanceEl);
fontCharRow.appendChild(c("td"));
unicodeRow.appendChild(c("td"));
}
}
if (str.length > 0) {
newArgs.push(str.join(""));
}
decArgs = [newArgs];
decArgs = c("td");
const table = c("table");
table.classList.add("showText");
decArgs.appendChild(table);
table.appendChild(charCodeRow);
table.appendChild(fontCharRow);
table.appendChild(unicodeRow);
}
line.appendChild(c("td", fn));
line.appendChild(c("td", JSON.stringify(simplifyArgs(decArgs))));
if (decArgs instanceof HTMLElement) {
line.appendChild(decArgs);
} else {
line.appendChild(c("td", JSON.stringify(simplifyArgs(decArgs))));
}
}
if (operatorsToDisplay < operatorList.fnArray.length) {
const lastCell = c("td", "...");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=Bal

loading_error=Bal otime kun cano PDF.
invalid_file_error=Pwail me PDF ma pe atir onyo obale woko.
missing_file_error=Pwail me PDF tye ka rem.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,7 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=Fout

loading_error='n Fout het voorgekom met die laai van die PDF.
invalid_file_error=Ongeldige of korrupte PDF-lêer.
missing_file_error=PDF-lêer is weg.
Expand Down
4 changes: 3 additions & 1 deletion content_plugin/assets/pdfjs/web/locale/an/viewer.properties
Original file line number Diff line number Diff line change
Expand Up @@ -151,9 +151,10 @@ thumbs_label=Miniaturas
findbar.title=Trobar en o documento
findbar_label=Trobar

additional_layers=Capas adicionals
# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
page_canvas=Pachina {{page}}

additional_layers=Capas adicionals
# Thumbnails panel item (tooltip and alt text for images)
# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page
# number.
Expand Down Expand Up @@ -227,6 +228,7 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=Error

loading_error=S'ha produciu una error en cargar o PDF.
invalid_file_error=O PDF no ye valido u ye estorbau.
missing_file_error=No i ha fichero PDF.
Expand Down
3 changes: 2 additions & 1 deletion content_plugin/assets/pdfjs/web/locale/ar/viewer.properties
Original file line number Diff line number Diff line change
Expand Up @@ -151,9 +151,10 @@ thumbs_label=مُصغّرات
findbar.title=ابحث في المستند
findbar_label=ابحث

additional_layers=الطبقات الإضافية
# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
page_canvas=صفحة {{page}}

additional_layers=الطبقات الإضافية
# LOCALIZATION NOTE (page_landmark): "{{page}}" will be replaced by the page number.
page_landmark=صفحة {{page}}
# Thumbnails panel item (tooltip and alt text for images)
Expand Down
4 changes: 3 additions & 1 deletion content_plugin/assets/pdfjs/web/locale/ast/viewer.properties
Original file line number Diff line number Diff line change
Expand Up @@ -127,9 +127,10 @@ thumbs.title=Amosar les miniatures
thumbs_label=Miniatures
findbar_label=Atopar

additional_layers=Capes adicionales
# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
page_canvas=Páxina {{page}}

additional_layers=Capes adicionales
# LOCALIZATION NOTE (page_landmark): "{{page}}" will be replaced by the page number.
page_landmark=Páxina {{page}}
# Thumbnails panel item (tooltip and alt text for images)
Expand Down Expand Up @@ -209,3 +210,4 @@ password_cancel=Encaboxar

# LOCALIZATION NOTE (unsupported_feature_signatures): Should contain the same
# exact string as in the `chrome.properties` file.

4 changes: 3 additions & 1 deletion content_plugin/assets/pdfjs/web/locale/az/viewer.properties
Original file line number Diff line number Diff line change
Expand Up @@ -151,9 +151,10 @@ thumbs_label=Kiçik şəkillər
findbar.title=Sənəddə Tap
findbar_label=Tap

additional_layers=Əlavə laylar
# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
page_canvas=Səhifə {{page}}

additional_layers=Əlavə laylar
# Thumbnails panel item (tooltip and alt text for images)
# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page
# number.
Expand Down Expand Up @@ -227,6 +228,7 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=Səhv

loading_error=PDF yüklenərkən bir səhv yarandı.
invalid_file_error=Səhv və ya zədələnmiş olmuş PDF fayl.
missing_file_error=PDF fayl yoxdur.
Expand Down
6 changes: 2 additions & 4 deletions content_plugin/assets/pdfjs/web/locale/be/viewer.properties
Original file line number Diff line number Diff line change
Expand Up @@ -153,9 +153,10 @@ current_outline_item_label=Бягучы элемент структуры
findbar.title=Пошук у дакуменце
findbar_label=Знайсці

additional_layers=Дадатковыя пласты
# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
page_canvas=Старонка {{page}}

additional_layers=Дадатковыя пласты
# LOCALIZATION NOTE (page_landmark): "{{page}}" will be replaced by the page number.
page_landmark=Старонка {{page}}
# Thumbnails panel item (tooltip and alt text for images)
Expand Down Expand Up @@ -256,6 +257,3 @@ password_cancel=Скасаваць
printing_not_supported=Папярэджанне: друк не падтрымліваецца цалкам гэтым браўзерам.
printing_not_ready=Увага: PDF не сцягнуты цалкам для друкавання.
web_fonts_disabled=Шрыфты Сеціва забаронены: немагчыма ўжываць укладзеныя шрыфты PDF.
# LOCALIZATION NOTE (unsupported_feature_signatures): Should contain the same
# exact string as in the `chrome.properties` file.
unsupported_feature_signatures=Гэты дакумент PDF змяшчае лічбавыя подпісы. Праверка подпісаў не падтрымліваецца.
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,7 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=Грешка

loading_error=Получи се грешка при зареждане на PDF-а.
invalid_file_error=Невалиден или повреден PDF файл.
missing_file_error=Липсващ PDF файл.
Expand Down
2 changes: 2 additions & 0 deletions content_plugin/assets/pdfjs/web/locale/bn/viewer.properties
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,7 @@ findbar_label=খুঁজুন

# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
page_canvas=পাতা {{page}}

# Thumbnails panel item (tooltip and alt text for images)
# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page
# number.
Expand Down Expand Up @@ -221,6 +222,7 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=ত্রুটি

loading_error=পিডিএফ লোড করার সময় ত্রুটি দেখা দিয়েছে।
invalid_file_error=অকার্যকর অথবা ক্ষতিগ্রস্ত পিডিএফ ফাইল।
missing_file_error=নিখোঁজ PDF ফাইল।
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,7 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=Error

loading_error=An error occurred while loading the PDF.
invalid_file_error=Invalid or corrupted PDF file.
missing_file_error=Missing PDF file.
Expand Down
8 changes: 8 additions & 0 deletions content_plugin/assets/pdfjs/web/locale/br/viewer.properties
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ document_outline.title=Diskouez steuñv an teul (daouglikit evit brasaat/bihanaa
document_outline_label=Sinedoù an teuliad
attachments.title=Diskouez ar c'henstagadurioù
attachments_label=Kenstagadurioù
layers.title=Diskouez ar gwiskadoù (daou-glikañ evit adderaouekaat an holl gwiskadoù d'o stad dre ziouer)
layers_label=Gwiskadoù
thumbs.title=Diskouez ar melvennoù
thumbs_label=Melvennoù
Expand All @@ -152,6 +153,10 @@ findbar_label=Klask

# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
page_canvas=Pajenn {{page}}

additional_layers=Gwiskadoù ouzhpenn
# LOCALIZATION NOTE (page_landmark): "{{page}}" will be replaced by the page number.
page_landmark=Pajenn {{page}}
# Thumbnails panel item (tooltip and alt text for images)
# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page
# number.
Expand Down Expand Up @@ -225,6 +230,9 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=Fazi

# Loading indicator messages
loading=O kargañ…
loading_error=Degouezhet ez eus bet ur fazi e-pad kargañ ar PDF.
invalid_file_error=Restr PDF didalvoudek pe kontronet.
missing_file_error=Restr PDF o vankout.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=गोरोन्थि

loading_error=PDF ल'ड खालामनाय समाव मोनसे गोरोन्थि जाबाय।
invalid_file_error=बाहायजायै एबा गाज्रि जानाय PDF फाइल
missing_file_error=गोमानाय PDF फाइल
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,7 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=Greška

loading_error=Došlo je do greške prilikom učitavanja PDF-a.
invalid_file_error=Neispravan ili oštećen PDF fajl.
missing_file_error=Nedostaje PDF fajl.
Expand Down
10 changes: 9 additions & 1 deletion content_plugin/assets/pdfjs/web/locale/ca/viewer.properties
Original file line number Diff line number Diff line change
Expand Up @@ -153,9 +153,12 @@ current_outline_item_label=Element d'esquema actual
findbar.title=Cerca al document
findbar_label=Cerca

additional_layers=Capes addicionals
# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
page_canvas=Pàgina {{page}}

additional_layers=Capes addicionals
# LOCALIZATION NOTE (page_landmark): "{{page}}" will be replaced by the page number.
page_landmark=Pàgina {{page}}
# Thumbnails panel item (tooltip and alt text for images)
# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page
# number.
Expand Down Expand Up @@ -229,6 +232,9 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=Error

# Loading indicator messages
loading=S'està carregant…
loading_error=S'ha produït un error en carregar el PDF.
invalid_file_error=El fitxer PDF no és vàlid o està malmès.
missing_file_error=Falta el fitxer PDF.
Expand All @@ -251,3 +257,5 @@ password_cancel=Cancel·la
printing_not_supported=Avís: la impressió no és plenament funcional en aquest navegador.
printing_not_ready=Atenció: el PDF no s'ha acabat de carregar per imprimir-lo.
web_fonts_disabled=Els tipus de lletra web estan desactivats: no es poden utilitzar els tipus de lletra incrustats al PDF.
# LOCALIZATION NOTE (unsupported_feature_signatures): Should contain the same
# exact string as in the `chrome.properties` file.
6 changes: 2 additions & 4 deletions content_plugin/assets/pdfjs/web/locale/cak/viewer.properties
Original file line number Diff line number Diff line change
Expand Up @@ -153,9 +153,10 @@ current_outline_item_label=Taq Ch'akulal Kik'wan Chib'äl
findbar.title=Tikanöx chupam ri wuj
findbar_label=Tikanöx

additional_layers=Tz'aqat ta Kuchuj
# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
page_canvas=Ruxaq {{page}}

additional_layers=Tz'aqat ta Kuchuj
# LOCALIZATION NOTE (page_landmark): "{{page}}" will be replaced by the page number.
page_landmark=Ruxaq {{page}}
# Thumbnails panel item (tooltip and alt text for images)
Expand Down Expand Up @@ -256,6 +257,3 @@ password_cancel=Tiq'at
printing_not_supported=Rutzijol k'ayewal: Ri rutz'ajb'axik man koch'el ta ronojel pa re okik'amaya'l re'.
printing_not_ready=Rutzijol k'ayewal: Ri PDF man xusamajij ta ronojel richin nitz'ajb'äx.
web_fonts_disabled=E chupül ri taq ajk'amaya'l tz'ib': man tikirel ta nokisäx ri taq tz'ib' PDF pa ch'ikenïk
# LOCALIZATION NOTE (unsupported_feature_signatures): Should contain the same
# exact string as in the `chrome.properties` file.
unsupported_feature_signatures=Re PDF ruk'wan tijital taq jux. Man nuköch' ta ri kijikib'axik taq jux.
4 changes: 3 additions & 1 deletion content_plugin/assets/pdfjs/web/locale/ckb/viewer.properties
Original file line number Diff line number Diff line change
Expand Up @@ -141,9 +141,10 @@ thumbs_label=وێنۆچکە
findbar.title=لە بەڵگەنامە بگەرێ
findbar_label=دۆزینەوە

additional_layers=چینی زیاتر
# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
page_canvas=پەڕەی {{page}}

additional_layers=چینی زیاتر
# Thumbnails panel item (tooltip and alt text for images)
# LOCALIZATION NOTE (thumb_page_title): "{{page}}" will be replaced by the page
# number.
Expand Down Expand Up @@ -217,6 +218,7 @@ page_scale_percent={{scale}}%

# Loading indicator messages
loading_error_indicator=هەڵە

loading_error=هەڵەیەک ڕوویدا لە کاتی بارکردنی PDF.
invalid_file_error=پەڕگەی pdf تێکچووە یان نەگونجاوە.
missing_file_error=پەڕگەی pdf بوونی نیە.
Expand Down
6 changes: 2 additions & 4 deletions content_plugin/assets/pdfjs/web/locale/cs/viewer.properties
Original file line number Diff line number Diff line change
Expand Up @@ -153,9 +153,10 @@ current_outline_item_label=Aktuální položka v osnově
findbar.title=Najde v dokumentu
findbar_label=Najít

additional_layers=Další vrstvy
# LOCALIZATION NOTE (page_canvas): "{{page}}" will be replaced by the page number.
page_canvas=Strana {{page}}

additional_layers=Další vrstvy
# LOCALIZATION NOTE (page_landmark): "{{page}}" will be replaced by the page number.
page_landmark=Strana {{page}}
# Thumbnails panel item (tooltip and alt text for images)
Expand Down Expand Up @@ -256,6 +257,3 @@ password_cancel=Zrušit
printing_not_supported=Upozornění: Tisk není v tomto prohlížeči plně podporován.
printing_not_ready=Upozornění: Dokument PDF není kompletně načten.
web_fonts_disabled=Webová písma jsou zakázána, proto není možné použít vložená písma PDF.
# LOCALIZATION NOTE (unsupported_feature_signatures): Should contain the same
# exact string as in the `chrome.properties` file.
unsupported_feature_signatures=Tento dokument typu PDF obsahuje digitální podpisy. Ověřování podpisů není podporováno.
Loading

0 comments on commit a164781

Please sign in to comment.