Skip to content

FilePicker: add an option to specify also the file name #2491

Description

@madbob

FilePicker misses an option to replicate a "Save As" functionality, in which the user can specify not only a path but also a (new) file name.

Probably this can be done with a new prop for the Vue component, fileName. If it is false (the default), just do nothing more than now. If it is a string, display a new editable text input field inited with the specified string.

It is debatable now to pass this new information to the buttons callback. Existing implementations with allowPickDirectory = true expect just a Folder item, and of course this cannot be broken; perhaps the callback can be called as callback(nodes, filename) (using the value of the new text input) when fileName != false.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions