diff --git a/assets/img/emptyTagRemoverExample.jpg b/assets/img/emptyTagRemoverExample.jpg new file mode 100644 index 0000000..ea5d34a Binary files /dev/null and b/assets/img/emptyTagRemoverExample.jpg differ diff --git a/assets/img/tagReparentExample.jpg b/assets/img/tagReparentExample.jpg new file mode 100644 index 0000000..14eba8d Binary files /dev/null and b/assets/img/tagReparentExample.jpg differ diff --git a/assets/img/tagShifterExample.jpg b/assets/img/tagShifterExample.jpg new file mode 100644 index 0000000..83ebc74 Binary files /dev/null and b/assets/img/tagShifterExample.jpg differ diff --git a/content/docs/tools/remove-empty-tags.md b/content/docs/tools/remove-empty-tags.md new file mode 100644 index 0000000..e61b2c9 --- /dev/null +++ b/content/docs/tools/remove-empty-tags.md @@ -0,0 +1,26 @@ +--- +weight: 308 +title: "Remove Empty Tags" +description: "" +icon: "article" +date: "2024-04-16T20:46:22-05:00" +lastmod: "2024-04-16T20:46:22-05:00" +draft: false +toc: true +--- + +This tool will remove any empty tags. This works in the same manner that the Above tool does. Note that you may need to run this tool several times if you have nested empty tags. + +This is commonly used with the [All Tags](/docs/selection/all-tags) selection. + +## Parameters + +This tool has no parameters. + +## Output + +Output showing that the empty tags were removed. After this tool was run, there were previously non-empty tags that are **now** empty. The remaining empty tags were **not** removed. This is because they were not empty when the tool checked for them. If you have an empty tag in an tag with no elements beside the empty tag, only the lowest child will be removed. You can run the tool multiple times to remove them all, or adjust your selection. + +Based on the order of the "All Tags" selection, the lowest Sect and last 2 Divs were removed. + +![The empty Div tag is removed after this tool is used..'](/img/emptyTagRemoverExample.jpg) \ No newline at end of file diff --git a/content/docs/tools/tag-reparent.md b/content/docs/tools/tag-reparent.md new file mode 100644 index 0000000..7a936e2 --- /dev/null +++ b/content/docs/tools/tag-reparent.md @@ -0,0 +1,28 @@ +--- +weight: 307 +title: "Tag Reparent" +description: "" +icon: "article" +date: "2024-04-16T20:24:30-05:00" +lastmod: "2024-04-16T20:24:30-05:00" +draft: false +toc: true +--- + +This tool can help to remove nested tags that are the same element type. **This is the same as the Tag-Shift tool, but this tool will move up the tag tree recursively until it finds a match.** Read the [Tag-Shifter](/docs/tools/tag-shift) documentation before using this tool. + +## Parameters + +The Tag Type must must match the selection for the child to be moved. The child element is the selection. This tool also has an option to automatically delete the parent tag if it is empty after the child has been moved. + +| Parameter | Purpose | +|-----------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| Tag Type | This is the type of tag that the toolset will search for. This is the *parent* element. If a child element is a distant child of this element, it will be moved up. | +| Delete if Empty | If the parent tag is empty after the child is moved, the parent tag will be deleted. | + + +## Output + +Output showing the nested tags on the left and the corrected tags on the right. This example moved the last P tag up to the section. The two Divs were not needed. While the original parent tag (2nd Div) was removed, the first Div was not. This is because the Tag Reparent Deletion only removes the original parent, not grandparent tags. If you want to remove empty tags that are not the direct parent, use the Empty Tag Remover tool. + +![Duplicate nested tags were moved out of their parent.'](/img/tagReparentExample.jpg) \ No newline at end of file diff --git a/content/docs/tools/tag-shift.md b/content/docs/tools/tag-shift.md new file mode 100644 index 0000000..d8a7a96 --- /dev/null +++ b/content/docs/tools/tag-shift.md @@ -0,0 +1,27 @@ +--- +weight: 306 +title: "Tag Shift" +description: "" +icon: "article" +date: "2024-04-16T20:07:52-05:00" +lastmod: "2024-04-16T20:07:52-05:00" +draft: false +toc: true +--- + +This tool can help to remove nested tags that are the same element type. Many PDFs have tags that unnecessarily encapsulate another tag. For example, a paragraph tag may incorrectly have a child paragraph tag. This tool will automatically move the child tag up one level, leaving the parent intact. If you want to delete the parent tag if it is empty, use the Remove Empty Tag tool after this one. + +## Parameters + +The Tag Type must must match the selection for the child to be moved. The child element is the selection. + +| Parameter | Purpose | +|-----------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| Tag Type | This is the type of tag that the toolset will search for. This is the *parent* element. If a child element is a direct child of this element, it will be moved up. | + + +## Output + +Output showing the nested tags on the left and the corrected tags on the right. The extra tags were moved to the bottom of the tag root (which happened to be the next parent.) + +![Duplicate nested tags were moved to the next parent at the end of the children list'](/img/tagShifterExample.jpg) \ No newline at end of file