Skip to content

Create the "Attachments" macro #82

Closed

Description

@snazare

Please create the "Attachments" macro, compatible with the Confluence Attachments macro: https://support.atlassian.com/confluence-cloud/docs/insert-the-attachments-macro/

Parameter Default Description
Filename Patterns(patterns) all A comma-separated list of regular expressions, used to filter the attachments by file name. Note that the parameter values must be regular expressions. For example:To match a file suffix of 'jpg', use .*jpg (not *.jpg).To match file names ending in 'jpg' or 'png', use .*jpg,.*png
Attachment Labels(labels) (none) A list of labels, used to filter the attachments to display. If you wish to enter more than one label, separate the labels with commas. Confluence will show only attachments that have all the labels specified. (The match is an AND, not an OR.) For information on labeling the attachments, see Use labels to organize pages and attachments.
Include Old Attachment Versions(old) false A value of true will include previous attachment versions in the list.
Sort By(sortBy) date The sort order for attachments. Note that people viewing the page can change the sort order by clicking the column headings. Valid values are:date – sorts by updated date in reverse chronological order (newest first)size – sorts largest to smallestname – sorts alphabeticallycreated date - sorts by creation date in reverse chronological order (newest first)
Sort Order(sortOrder) ascending Used in combination with the Sort By parameter, to sort the attachments in ascending or descending order.
Allow Upload(upload) true If selected, the list of attachments will include options allowing users to browse for, and attach, new files.
Page Title(page) (none) Used to display attachments from another page. If you do not enter a page title, the macro will display the files attached to the current page.
Show Previews(preview) true Used to display a preview of the attached file. If true, preview will be visible when the list item is expanded.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions