Skip to content

Commit

Permalink
Merge pull request #381 from veraPDF/update_profiles
Browse files Browse the repository at this point in the history
Update WCAG and PDF/UA rules
  • Loading branch information
MaximPlusov authored Nov 30, 2023
2 parents 0463644 + 9672e27 commit 763145b
Show file tree
Hide file tree
Showing 71 changed files with 1,441 additions and 327 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/update-PDFUA-profiles-workflow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Update PDF_UA profiles

on:
push:
branches:
[ integration ]
paths:
- 'PDF_UA/1/**'
- 'PDF_UA/2/**'
- 'PDF_UA/WCAG/PDF_UA/**'
- 'PDF_UA/WCAG-21.xml'

jobs:
update-profiles:
if: github.repository == 'veraPDF/veraPDF-validation-profiles'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
token: ${{ secrets.WORKFLOW_TOKEN }}
- name: Set up JDK 1.11
uses: actions/setup-java@v1
with:
java-version: 1.11
- name: Generate PDF_UA profiles
run: |
curl -LO https://raw.githubusercontent.com/veraPDF/veraPDF-tools/master/profile-merger/profile-merger-1.0-SNAPSHOT.jar
java -jar profile-merger-1.0-SNAPSHOT.jar pdfua
rm profile-merger-1.0-SNAPSHOT.jar
- name: Push PDF_UA profiles
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: ${{ github.event.head_commit.message }}

- name: Notify slack if action didn't run
if: failure()
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_NOTIFICATIONS_BOT_TOKEN }}
uses: voxmedia/github-action-slack-notify-build@v1
with:
channel_id: C03E3JJGLQL
status: FAILED
color: danger
187 changes: 0 additions & 187 deletions PDF_UA/1/7.2 Text/verapdf-profile-7-2-t03-t15.xml

This file was deleted.

27 changes: 27 additions & 0 deletions PDF_UA/1/7.2 Text/verapdf-profile-7-2-t03.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<profile xmlns="http://www.verapdf.org/ValidationProfile" flavour="PDFUA_1">
<details creator="veraPDF Consortium" created="2020-03-13T10:58:04.098+03:00">
<name>ISO 14289-1:2014 - 7.2 Text - children of Table</name>
<description>Table element may contain only TR, THead, TBody, TFoot and Caption elements</description>
</details>
<hash></hash>
<rules>
<rule object="SETable" tags="major,machine,structure,table">
<id specification="ISO_14289_1" clause="7.2" testNumber="3"/>
<description>Table element may contain only TR, THead, TBody, TFoot and Caption elements</description>
<test>kidsStandardTypes.split('&amp;').filter(elem =&gt; elem != 'TR' &amp;&amp; elem != 'THead'
&amp;&amp; elem != 'TBody' &amp;&amp; elem != 'TFoot' &amp;&amp; elem != 'Caption').length == 0 || kidsStandardTypes == ''</test>
<error>
<message>Table element contains %1 element(s) instead of TR, THead, TBode, TFoot or Caption</message>
<arguments>
<argument>kidsStandardTypes.split('&amp;').filter(elem =&gt; elem != 'TR' &amp;&amp; elem != 'THead'
&amp;&amp; elem != 'TBody' &amp;&amp; elem != 'TFoot' &amp;&amp; elem != 'Caption').toString()</argument>
</arguments>
</error>
<references>
<reference specification="ISO 32000-1:2008" clause="14.8.4.3.4"/>
</references>
</rule>
</rules>
<variables/>
</profile>
25 changes: 25 additions & 0 deletions PDF_UA/1/7.2 Text/verapdf-profile-7-2-t04.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<profile xmlns="http://www.verapdf.org/ValidationProfile" flavour="PDFUA_1">
<details creator="veraPDF Consortium" created="2020-03-13T10:58:04.098+03:00">
<name>ISO 14289-1:2014 - 7.2 Text - parent of TR</name>
<description>TR element should be contained in Table, THead, TBody or TFoot element</description>
</details>
<hash></hash>
<rules>
<rule object="SETR" tags="major,machine,structure,table">
<id specification="ISO_14289_1" clause="7.2" testNumber="4"/>
<description>TR element should be contained in Table, THead, TBody or TFoot element</description>
<test>/^(Table|THead|TBody|TFoot)$/.test(parentStandardType)</test>
<error>
<message>TR element contained in %1 instead of Table, THead, TBody or TFoot element</message>
<arguments>
<argument>parentStandardType</argument>
</arguments>
</error>
<references>
<reference specification="ISO 32000-1:2008" clause="14.8.4.3.4"/>
</references>
</rule>
</rules>
<variables/>
</profile>
25 changes: 25 additions & 0 deletions PDF_UA/1/7.2 Text/verapdf-profile-7-2-t05.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<profile xmlns="http://www.verapdf.org/ValidationProfile" flavour="PDFUA_1">
<details creator="veraPDF Consortium" created="2020-03-13T10:58:04.098+03:00">
<name>ISO 14289-1:2014 - 7.2 Text - parent of THead</name>
<description>THead element should be contained in Table element</description>
</details>
<hash></hash>
<rules>
<rule object="SETHead" tags="major,machine,structure,table">
<id specification="ISO_14289_1" clause="7.2" testNumber="5"/>
<description>THead element should be contained in Table element</description>
<test>parentStandardType == 'Table'</test>
<error>
<message>THead element contained in %1 instead of Table element</message>
<arguments>
<argument>parentStandardType</argument>
</arguments>
</error>
<references>
<reference specification="ISO 32000-1:2008" clause="14.8.4.3.4"/>
</references>
</rule>
</rules>
<variables/>
</profile>
25 changes: 25 additions & 0 deletions PDF_UA/1/7.2 Text/verapdf-profile-7-2-t06.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<profile xmlns="http://www.verapdf.org/ValidationProfile" flavour="PDFUA_1">
<details creator="veraPDF Consortium" created="2020-03-13T10:58:04.098+03:00">
<name>ISO 14289-1:2014 - 7.2 Text - parent of TBody</name>
<description>TBody element should be contained in Table element</description>
</details>
<hash></hash>
<rules>
<rule object="SETBody" tags="major,machine,structure,table">
<id specification="ISO_14289_1" clause="7.2" testNumber="6"/>
<description>TBody element should be contained in Table element</description>
<test>parentStandardType == 'Table'</test>
<error>
<message>TBody element contained in %1 instead of Table element</message>
<arguments>
<argument>parentStandardType</argument>
</arguments>
</error>
<references>
<reference specification="ISO 32000-1:2008" clause="14.8.4.3.4"/>
</references>
</rule>
</rules>
<variables/>
</profile>
25 changes: 25 additions & 0 deletions PDF_UA/1/7.2 Text/verapdf-profile-7-2-t07.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<profile xmlns="http://www.verapdf.org/ValidationProfile" flavour="PDFUA_1">
<details creator="veraPDF Consortium" created="2020-03-13T10:58:04.098+03:00">
<name>ISO 14289-1:2014 - 7.2 Text - parent of TFoot</name>
<description>TFoot element should be contained in Table element</description>
</details>
<hash></hash>
<rules>
<rule object="SETFoot" tags="major,machine,structure,table">
<id specification="ISO_14289_1" clause="7.2" testNumber="7"/>
<description>TFoot element should be contained in Table element</description>
<test>parentStandardType == 'Table'</test>
<error>
<message>TFoot element contained in %1 instead of Table element</message>
<arguments>
<argument>parentStandardType</argument>
</arguments>
</error>
<references>
<reference specification="ISO 32000-1:2008" clause="14.8.4.3.4"/>
</references>
</rule>
</rules>
<variables/>
</profile>
25 changes: 25 additions & 0 deletions PDF_UA/1/7.2 Text/verapdf-profile-7-2-t08.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<profile xmlns="http://www.verapdf.org/ValidationProfile" flavour="PDFUA_1">
<details creator="veraPDF Consortium" created="2020-03-13T10:58:04.098+03:00">
<name>ISO 14289-1:2014 - 7.2 Text - parent of TH</name>
<description>TH element should be contained in TR element</description>
</details>
<hash></hash>
<rules>
<rule object="SETH" tags="major,machine,structure,table">
<id specification="ISO_14289_1" clause="7.2" testNumber="8"/>
<description>TH element should be contained in TR element</description>
<test>parentStandardType == 'TR'</test>
<error>
<message>TH element contained in %1 instead of TR element</message>
<arguments>
<argument>parentStandardType</argument>
</arguments>
</error>
<references>
<reference specification="ISO 32000-1:2008" clause="14.8.4.3.4"/>
</references>
</rule>
</rules>
<variables/>
</profile>
Loading

0 comments on commit 763145b

Please sign in to comment.