summaryrefslogtreecommitdiff
path: root/vendor/github.com/playwright-community/playwright-go/file_chooser.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/playwright-community/playwright-go/file_chooser.go')
-rw-r--r--vendor/github.com/playwright-community/playwright-go/file_chooser.go44
1 files changed, 0 insertions, 44 deletions
diff --git a/vendor/github.com/playwright-community/playwright-go/file_chooser.go b/vendor/github.com/playwright-community/playwright-go/file_chooser.go
deleted file mode 100644
index 119e885..0000000
--- a/vendor/github.com/playwright-community/playwright-go/file_chooser.go
+++ /dev/null
@@ -1,44 +0,0 @@
-package playwright
-
-type fileChooserImpl struct {
- page Page
- elementHandle ElementHandle
- isMultiple bool
-}
-
-func (f *fileChooserImpl) Page() Page {
- return f.page
-}
-
-func (f *fileChooserImpl) Element() ElementHandle {
- return f.elementHandle
-}
-
-func (f *fileChooserImpl) IsMultiple() bool {
- return f.isMultiple
-}
-
-// InputFile represents the input file for:
-// - FileChooser.SetFiles()
-// - ElementHandle.SetInputFiles()
-// - Page.SetInputFiles()
-type InputFile struct {
- Name string `json:"name"`
- MimeType string `json:"mimeType,omitempty"`
- Buffer []byte `json:"buffer"`
-}
-
-func (f *fileChooserImpl) SetFiles(files interface{}, options ...FileChooserSetFilesOptions) error {
- if len(options) == 1 {
- return f.elementHandle.SetInputFiles(files, ElementHandleSetInputFilesOptions(options[0]))
- }
- return f.elementHandle.SetInputFiles(files)
-}
-
-func newFileChooser(page Page, elementHandle ElementHandle, isMultiple bool) *fileChooserImpl {
- return &fileChooserImpl{
- page: page,
- elementHandle: elementHandle,
- isMultiple: isMultiple,
- }
-}