scrapfly-sdk 0.5.1 → 0.6.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +35 -14
- package/esm/_dnt.shims.d.ts +6 -0
- package/esm/_dnt.shims.d.ts.map +1 -0
- package/esm/_dnt.shims.js +61 -0
- package/esm/client.d.ts +70 -0
- package/esm/client.d.ts.map +1 -0
- package/esm/client.js +364 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/assert_path.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/assert_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/assert_path.js +7 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/basename.d.ts +4 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/basename.js +40 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/common.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/common.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/common.js +23 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/constants.d.ts +40 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/constants.js +46 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/dirname.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/dirname.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/format.d.ts +4 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/format.js +19 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/from_file_url.d.ts +3 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/from_file_url.js +9 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/glob_to_reg_exp.d.ts +35 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/glob_to_reg_exp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/glob_to_reg_exp.js +234 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/normalize.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/normalize.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/normalize_string.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/normalize_string.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/normalize_string.js +77 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/relative.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/relative.js +9 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/strip_trailing_separators.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/strip_trailing_separators.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/strip_trailing_separators.js +19 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/to_file_url.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_common/to_file_url.js +15 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_os.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_os.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/_os.js +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/basename.d.ts +25 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/basename.js +33 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/common.d.ts +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/common.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/common.js +33 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/constants.d.ts +15 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/constants.js +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/dirname.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/dirname.js +26 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/extname.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/extname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/extname.js +26 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/format.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/format.js +27 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/from_file_url.d.ts +23 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/from_file_url.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/glob_to_regexp.d.ts +77 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/glob_to_regexp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/glob_to_regexp.js +83 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/is_absolute.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/is_absolute.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/is_absolute.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/is_glob.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/is_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/is_glob.js +42 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/join.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/join.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/join.js +26 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/join_globs.d.ts +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/join_globs.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/join_globs.js +34 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/mod.d.ts +51 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/mod.js +54 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/normalize.d.ts +24 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/normalize.js +30 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/normalize_glob.d.ts +29 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/normalize_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/normalize_glob.js +35 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/parse.d.ts +35 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/parse.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/parse.js +39 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/_util.d.ts +2 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/_util.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/_util.js +8 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/basename.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/basename.js +29 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/constants.d.ts +13 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/constants.js +14 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/dirname.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/dirname.js +47 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/extname.d.ts +18 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/extname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/extname.js +70 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/format.d.ts +24 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/format.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/from_file_url.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/from_file_url.js +21 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/glob_to_regexp.d.ts +72 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/glob_to_regexp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/glob_to_regexp.js +82 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/is_absolute.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/is_absolute.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/is_absolute.js +23 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/join.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/join.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/join.js +26 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/join_globs.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/join_globs.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/join_globs.js +39 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/normalize.d.ts +19 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/normalize.js +36 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/normalize_glob.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/normalize_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/normalize_glob.js +31 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/parse.d.ts +25 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/parse.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/parse.js +115 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/relative.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/relative.js +106 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/resolve.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/resolve.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/resolve.js +59 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/to_file_url.d.ts +18 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/to_file_url.js +27 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/to_namespaced_path.d.ts +16 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/to_namespaced_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/posix/to_namespaced_path.js +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/relative.d.ts +24 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/relative.js +30 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/resolve.d.ts +22 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/resolve.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/resolve.js +30 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/to_file_url.d.ts +23 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/to_file_url.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/to_namespaced_path.d.ts +21 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/to_namespaced_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/to_namespaced_path.js +29 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/types.d.ts +38 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/types.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/types.js +3 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/_util.d.ts +4 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/_util.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/_util.js +15 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/basename.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/basename.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/basename.js +41 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/constants.d.ts +13 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/constants.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/constants.js +14 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/dirname.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/dirname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/dirname.js +109 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/extname.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/extname.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/extname.js +78 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/format.d.ts +24 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/format.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/format.js +28 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/from_file_url.d.ts +19 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/from_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/from_file_url.js +30 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/glob_to_regexp.d.ts +71 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/glob_to_regexp.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/glob_to_regexp.js +82 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/is_absolute.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/is_absolute.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/is_absolute.js +38 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/join.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/join.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/join.js +71 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/join_globs.d.ts +21 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/join_globs.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/join_globs.js +40 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/normalize.d.ts +19 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/normalize.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/normalize.js +131 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/normalize_glob.d.ts +20 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/normalize_glob.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/normalize_glob.js +31 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/parse.d.ts +25 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/parse.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/parse.js +176 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/relative.d.ts +23 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/relative.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/relative.js +131 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/resolve.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/resolve.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/resolve.js +154 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/to_file_url.d.ts +18 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/to_file_url.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/to_file_url.js +34 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/to_namespaced_path.d.ts +17 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/to_namespaced_path.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/path/1.0.1/windows/to_namespaced_path.js +49 -0
- package/esm/deps.d.ts +4 -0
- package/esm/deps.d.ts.map +1 -0
- package/esm/deps.js +3 -0
- package/{build/src → esm}/errors.d.ts +9 -0
- package/esm/errors.d.ts.map +1 -0
- package/{build/src → esm}/errors.js +19 -3
- package/esm/extractionconfig.d.ts +47 -0
- package/esm/extractionconfig.d.ts.map +1 -0
- package/esm/extractionconfig.js +156 -0
- package/{build/src → esm}/logger.d.ts +1 -0
- package/esm/logger.d.ts.map +1 -0
- package/{build/src → esm}/logger.js +12 -3
- package/esm/main.d.ts +9 -0
- package/esm/main.d.ts.map +1 -0
- package/esm/main.js +7 -0
- package/esm/package.json +3 -0
- package/esm/polyfill.d.ts +6 -0
- package/esm/polyfill.d.ts.map +1 -0
- package/esm/polyfill.js +20 -0
- package/{build/src → esm}/result.d.ts +30 -4
- package/esm/result.d.ts.map +1 -0
- package/esm/result.js +118 -0
- package/esm/scrapeconfig.d.ts +120 -0
- package/esm/scrapeconfig.d.ts.map +1 -0
- package/esm/scrapeconfig.js +505 -0
- package/esm/screenshotconfig.d.ts +69 -0
- package/esm/screenshotconfig.d.ts.map +1 -0
- package/esm/screenshotconfig.js +220 -0
- package/{build/src → esm}/types.d.ts +1 -0
- package/esm/types.d.ts.map +1 -0
- package/esm/types.js +1 -0
- package/esm/utils.d.ts +10 -0
- package/esm/utils.d.ts.map +1 -0
- package/esm/utils.js +40 -0
- package/package.json +36 -61
- package/script/_dnt.shims.d.ts +6 -0
- package/script/_dnt.shims.d.ts.map +1 -0
- package/script/_dnt.shims.js +65 -0
- package/script/client.d.ts +70 -0
- package/script/client.d.ts.map +1 -0
- package/script/client.js +391 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/assert_path.d.ts +2 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/assert_path.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/assert_path.js +11 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/basename.d.ts +4 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/basename.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/basename.js +46 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/common.d.ts +2 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/common.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/common.js +27 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/constants.d.ts +40 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/constants.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/constants.js +49 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/dirname.d.ts +2 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/dirname.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/dirname.js +12 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/format.d.ts +4 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/format.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/format.js +24 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/from_file_url.d.ts +3 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/from_file_url.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/from_file_url.js +13 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/glob_to_reg_exp.d.ts +35 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/glob_to_reg_exp.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/glob_to_reg_exp.js +238 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/normalize.d.ts +2 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/normalize.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/normalize.js +12 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/normalize_string.d.ts +2 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/normalize_string.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/normalize_string.js +81 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/relative.d.ts +2 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/relative.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/relative.js +13 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/strip_trailing_separators.d.ts +2 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/strip_trailing_separators.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/strip_trailing_separators.js +23 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/to_file_url.d.ts +2 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/to_file_url.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_common/to_file_url.js +19 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_os.d.ts +2 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_os.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/_os.js +43 -0
- package/script/deps/jsr.io/@std/path/1.0.1/basename.d.ts +25 -0
- package/script/deps/jsr.io/@std/path/1.0.1/basename.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/basename.js +37 -0
- package/script/deps/jsr.io/@std/path/1.0.1/common.d.ts +28 -0
- package/script/deps/jsr.io/@std/path/1.0.1/common.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/common.js +37 -0
- package/script/deps/jsr.io/@std/path/1.0.1/constants.d.ts +15 -0
- package/script/deps/jsr.io/@std/path/1.0.1/constants.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/constants.js +20 -0
- package/script/deps/jsr.io/@std/path/1.0.1/dirname.d.ts +20 -0
- package/script/deps/jsr.io/@std/path/1.0.1/dirname.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/dirname.js +30 -0
- package/script/deps/jsr.io/@std/path/1.0.1/extname.d.ts +20 -0
- package/script/deps/jsr.io/@std/path/1.0.1/extname.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/extname.js +30 -0
- package/script/deps/jsr.io/@std/path/1.0.1/format.d.ts +22 -0
- package/script/deps/jsr.io/@std/path/1.0.1/format.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/format.js +31 -0
- package/script/deps/jsr.io/@std/path/1.0.1/from_file_url.d.ts +23 -0
- package/script/deps/jsr.io/@std/path/1.0.1/from_file_url.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/from_file_url.js +32 -0
- package/script/deps/jsr.io/@std/path/1.0.1/glob_to_regexp.d.ts +77 -0
- package/script/deps/jsr.io/@std/path/1.0.1/glob_to_regexp.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/glob_to_regexp.js +87 -0
- package/script/deps/jsr.io/@std/path/1.0.1/is_absolute.d.ts +22 -0
- package/script/deps/jsr.io/@std/path/1.0.1/is_absolute.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/is_absolute.js +32 -0
- package/script/deps/jsr.io/@std/path/1.0.1/is_glob.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/is_glob.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/is_glob.js +46 -0
- package/script/deps/jsr.io/@std/path/1.0.1/join.d.ts +20 -0
- package/script/deps/jsr.io/@std/path/1.0.1/join.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/join.js +30 -0
- package/script/deps/jsr.io/@std/path/1.0.1/join_globs.d.ts +28 -0
- package/script/deps/jsr.io/@std/path/1.0.1/join_globs.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/join_globs.js +38 -0
- package/script/deps/jsr.io/@std/path/1.0.1/mod.d.ts +51 -0
- package/script/deps/jsr.io/@std/path/1.0.1/mod.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/mod.js +70 -0
- package/script/deps/jsr.io/@std/path/1.0.1/normalize.d.ts +24 -0
- package/script/deps/jsr.io/@std/path/1.0.1/normalize.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/normalize.js +34 -0
- package/script/deps/jsr.io/@std/path/1.0.1/normalize_glob.d.ts +29 -0
- package/script/deps/jsr.io/@std/path/1.0.1/normalize_glob.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/normalize_glob.js +39 -0
- package/script/deps/jsr.io/@std/path/1.0.1/parse.d.ts +35 -0
- package/script/deps/jsr.io/@std/path/1.0.1/parse.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/parse.js +43 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/_util.d.ts +2 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/_util.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/_util.js +12 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/basename.d.ts +20 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/basename.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/basename.js +33 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/constants.d.ts +13 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/constants.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/constants.js +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/dirname.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/dirname.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/dirname.js +51 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/extname.d.ts +18 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/extname.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/extname.js +74 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/format.d.ts +24 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/format.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/format.js +32 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/from_file_url.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/from_file_url.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/from_file_url.js +25 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/glob_to_regexp.d.ts +72 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/glob_to_regexp.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/glob_to_regexp.js +86 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/is_absolute.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/is_absolute.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/is_absolute.js +27 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/join.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/join.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/join.js +30 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/join_globs.d.ts +20 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/join_globs.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/join_globs.js +43 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/normalize.d.ts +19 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/normalize.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/normalize.js +40 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/normalize_glob.d.ts +20 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/normalize_glob.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/normalize_glob.js +35 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/parse.d.ts +25 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/parse.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/parse.js +119 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/relative.d.ts +20 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/relative.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/relative.js +110 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/resolve.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/resolve.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/resolve.js +86 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/to_file_url.d.ts +18 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/to_file_url.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/to_file_url.js +31 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/to_namespaced_path.d.ts +16 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/to_namespaced_path.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/posix/to_namespaced_path.js +24 -0
- package/script/deps/jsr.io/@std/path/1.0.1/relative.d.ts +24 -0
- package/script/deps/jsr.io/@std/path/1.0.1/relative.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/relative.js +34 -0
- package/script/deps/jsr.io/@std/path/1.0.1/resolve.d.ts +22 -0
- package/script/deps/jsr.io/@std/path/1.0.1/resolve.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/resolve.js +34 -0
- package/script/deps/jsr.io/@std/path/1.0.1/to_file_url.d.ts +23 -0
- package/script/deps/jsr.io/@std/path/1.0.1/to_file_url.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/to_file_url.js +32 -0
- package/script/deps/jsr.io/@std/path/1.0.1/to_namespaced_path.d.ts +21 -0
- package/script/deps/jsr.io/@std/path/1.0.1/to_namespaced_path.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/to_namespaced_path.js +33 -0
- package/script/deps/jsr.io/@std/path/1.0.1/types.d.ts +38 -0
- package/script/deps/jsr.io/@std/path/1.0.1/types.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/types.js +4 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/_util.d.ts +4 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/_util.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/_util.js +21 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/basename.d.ts +20 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/basename.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/basename.js +45 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/constants.d.ts +13 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/constants.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/constants.js +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/dirname.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/dirname.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/dirname.js +113 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/extname.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/extname.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/extname.js +82 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/format.d.ts +24 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/format.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/format.js +32 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/from_file_url.d.ts +19 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/from_file_url.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/from_file_url.js +34 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/glob_to_regexp.d.ts +71 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/glob_to_regexp.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/glob_to_regexp.js +86 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/is_absolute.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/is_absolute.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/is_absolute.js +42 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/join.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/join.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/join.js +75 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/join_globs.d.ts +21 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/join_globs.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/join_globs.js +44 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/normalize.d.ts +19 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/normalize.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/normalize.js +135 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/normalize_glob.d.ts +20 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/normalize_glob.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/normalize_glob.js +35 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/parse.d.ts +25 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/parse.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/parse.js +180 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/relative.d.ts +23 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/relative.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/relative.js +135 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/resolve.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/resolve.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/resolve.js +181 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/to_file_url.d.ts +18 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/to_file_url.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/to_file_url.js +38 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/to_namespaced_path.d.ts +17 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/to_namespaced_path.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/path/1.0.1/windows/to_namespaced_path.js +53 -0
- package/script/deps.d.ts +4 -0
- package/script/deps.d.ts.map +1 -0
- package/script/deps.js +30 -0
- package/script/errors.d.ts +53 -0
- package/script/errors.d.ts.map +1 -0
- package/script/errors.js +102 -0
- package/script/extractionconfig.d.ts +47 -0
- package/script/extractionconfig.d.ts.map +1 -0
- package/script/extractionconfig.js +183 -0
- package/script/logger.d.ts +19 -0
- package/script/logger.d.ts.map +1 -0
- package/script/logger.js +58 -0
- package/script/main.d.ts +9 -0
- package/script/main.d.ts.map +1 -0
- package/script/main.js +46 -0
- package/script/package.json +3 -0
- package/script/polyfill.d.ts +6 -0
- package/script/polyfill.d.ts.map +1 -0
- package/script/polyfill.js +48 -0
- package/script/result.d.ts +297 -0
- package/script/result.d.ts.map +1 -0
- package/script/result.js +147 -0
- package/script/scrapeconfig.d.ts +120 -0
- package/script/scrapeconfig.d.ts.map +1 -0
- package/script/scrapeconfig.js +509 -0
- package/script/screenshotconfig.d.ts +69 -0
- package/script/screenshotconfig.d.ts.map +1 -0
- package/script/screenshotconfig.js +224 -0
- package/script/types.d.ts +3 -0
- package/script/types.d.ts.map +1 -0
- package/script/types.js +2 -0
- package/script/utils.d.ts +10 -0
- package/script/utils.d.ts.map +1 -0
- package/script/utils.js +45 -0
- package/build/src/client.d.ts +0 -45
- package/build/src/client.js +0 -199
- package/build/src/client.js.map +0 -1
- package/build/src/errors.js.map +0 -1
- package/build/src/logger.js.map +0 -1
- package/build/src/main.d.ts +0 -5
- package/build/src/main.js +0 -6
- package/build/src/main.js.map +0 -1
- package/build/src/result.js +0 -30
- package/build/src/result.js.map +0 -1
- package/build/src/scrapeconfig.d.ts +0 -85
- package/build/src/scrapeconfig.js +0 -257
- package/build/src/scrapeconfig.js.map +0 -1
- package/build/src/types.js +0 -2
- package/build/src/types.js.map +0 -1
- package/build/src/utils.d.ts +0 -1
- package/build/src/utils.js +0 -7
- package/build/src/utils.js.map +0 -1
package/script/client.js
ADDED
|
@@ -0,0 +1,391 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
exports.ScrapflyClient = void 0;
|
|
27
|
+
const deps_js_1 = require("./deps.js");
|
|
28
|
+
const polyfill_js_1 = require("./polyfill.js");
|
|
29
|
+
const utils_js_1 = require("./utils.js");
|
|
30
|
+
const errors = __importStar(require("./errors.js"));
|
|
31
|
+
const result_js_1 = require("./result.js");
|
|
32
|
+
const logger_js_1 = require("./logger.js");
|
|
33
|
+
class ScrapflyClient {
|
|
34
|
+
constructor(options) {
|
|
35
|
+
Object.defineProperty(this, "HOST", {
|
|
36
|
+
enumerable: true,
|
|
37
|
+
configurable: true,
|
|
38
|
+
writable: true,
|
|
39
|
+
value: 'https://api.scrapfly.io'
|
|
40
|
+
});
|
|
41
|
+
Object.defineProperty(this, "key", {
|
|
42
|
+
enumerable: true,
|
|
43
|
+
configurable: true,
|
|
44
|
+
writable: true,
|
|
45
|
+
value: void 0
|
|
46
|
+
});
|
|
47
|
+
Object.defineProperty(this, "ua", {
|
|
48
|
+
enumerable: true,
|
|
49
|
+
configurable: true,
|
|
50
|
+
writable: true,
|
|
51
|
+
value: void 0
|
|
52
|
+
});
|
|
53
|
+
Object.defineProperty(this, "fetch", {
|
|
54
|
+
enumerable: true,
|
|
55
|
+
configurable: true,
|
|
56
|
+
writable: true,
|
|
57
|
+
value: utils_js_1.fetchRetry
|
|
58
|
+
});
|
|
59
|
+
if (typeof options.key !== 'string' || options.key.trim() === '') {
|
|
60
|
+
throw new errors.BadApiKeyError('Invalid key. Key must be a non-empty string');
|
|
61
|
+
}
|
|
62
|
+
this.key = options.key;
|
|
63
|
+
this.ua = 'Typescript Scrapfly SDK';
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Raise appropriate error for given response and scrape result
|
|
67
|
+
*/
|
|
68
|
+
errResult(response, result) {
|
|
69
|
+
const error = result.result.error;
|
|
70
|
+
const message = error?.message ?? '';
|
|
71
|
+
const args = {
|
|
72
|
+
code: result.result.status,
|
|
73
|
+
http_status_code: result.result.status_code,
|
|
74
|
+
is_retryable: error?.retryable ?? false,
|
|
75
|
+
api_response: result,
|
|
76
|
+
resource: result.result.status ? result.result.status.split('::')[1] : null,
|
|
77
|
+
retry_delay: error?.retryable ? 5 : response.headers.get('X-Retry') ?? 5,
|
|
78
|
+
retry_times: 3,
|
|
79
|
+
documentation_url: error?.doc_url ?? 'https://scrapfly.io/docs/scrape-api/errors#api',
|
|
80
|
+
};
|
|
81
|
+
if (result.result.success === true) {
|
|
82
|
+
switch (args.http_status_code) {
|
|
83
|
+
case 500:
|
|
84
|
+
return new errors.ApiHttpServerError(message, args);
|
|
85
|
+
case 401:
|
|
86
|
+
return new errors.BadApiKeyError(message, args);
|
|
87
|
+
case 429:
|
|
88
|
+
return new errors.TooManyRequests(message, args);
|
|
89
|
+
}
|
|
90
|
+
switch (args.resource) {
|
|
91
|
+
case 'SCRAPE':
|
|
92
|
+
return new errors.ScrapflyScrapeError(message, args);
|
|
93
|
+
case 'WEBHOOK':
|
|
94
|
+
return new errors.ScrapflyWebhookError(message, args);
|
|
95
|
+
case 'PROXY':
|
|
96
|
+
return new errors.ScrapflyProxyError(message, args);
|
|
97
|
+
case 'SCHEDULE':
|
|
98
|
+
return new errors.ScrapflyScheduleError(message, args);
|
|
99
|
+
case 'ASP':
|
|
100
|
+
return new errors.ScrapflyAspError(message, args);
|
|
101
|
+
case 'SESSION':
|
|
102
|
+
return new errors.ScrapflySessionError(message, args);
|
|
103
|
+
}
|
|
104
|
+
if (args.resource) {
|
|
105
|
+
return new errors.ApiHttpClientError(message, args);
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
else {
|
|
109
|
+
if (args.code === 'ERR::SCRAPE::BAD_UPSTREAM_RESPONSE') {
|
|
110
|
+
if (args.http_status_code >= 400 && args.http_status_code < 500) {
|
|
111
|
+
return new errors.UpstreamHttpClientError(message, args);
|
|
112
|
+
}
|
|
113
|
+
if (args.http_status_code >= 500 && args.http_status_code < 600) {
|
|
114
|
+
return new errors.UpstreamHttpServerError(message, args);
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
switch (args.resource) {
|
|
118
|
+
case 'SCRAPE':
|
|
119
|
+
return new errors.ScrapflyScrapeError(message, args);
|
|
120
|
+
case 'WEBHOOK':
|
|
121
|
+
return new errors.ScrapflyWebhookError(message, args);
|
|
122
|
+
case 'PROXY':
|
|
123
|
+
return new errors.ScrapflyProxyError(message, args);
|
|
124
|
+
case 'SCHEDULE':
|
|
125
|
+
return new errors.ScrapflyScheduleError(message, args);
|
|
126
|
+
case 'ASP':
|
|
127
|
+
return new errors.ScrapflyAspError(message, args);
|
|
128
|
+
case 'SESSION':
|
|
129
|
+
return new errors.ScrapflySessionError(message, args);
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
return new errors.ScrapflyError(message, args);
|
|
133
|
+
}
|
|
134
|
+
/**
|
|
135
|
+
* Turn scrapfly API response to ScrapeResult or raise one of ScrapflyError
|
|
136
|
+
*/
|
|
137
|
+
handleResponse(response, result) {
|
|
138
|
+
// success
|
|
139
|
+
logger_js_1.log.debug('scrape log url: ', result.result.log_url);
|
|
140
|
+
if (result.result.status === 'DONE' && result.result.success === true) {
|
|
141
|
+
return result;
|
|
142
|
+
}
|
|
143
|
+
// something went wrong
|
|
144
|
+
throw this.errResult(response, result);
|
|
145
|
+
}
|
|
146
|
+
/**
|
|
147
|
+
* Retrieve Scrapfly account details
|
|
148
|
+
*/
|
|
149
|
+
async account() {
|
|
150
|
+
logger_js_1.log.debug('retrieving account info');
|
|
151
|
+
let response;
|
|
152
|
+
try {
|
|
153
|
+
const url = new URL(this.HOST + '/account');
|
|
154
|
+
const params = { key: this.key };
|
|
155
|
+
url.search = new URLSearchParams(params).toString();
|
|
156
|
+
response = await this.fetch({
|
|
157
|
+
url: url.toString(),
|
|
158
|
+
method: 'GET',
|
|
159
|
+
headers: {
|
|
160
|
+
'user-agent': this.ua,
|
|
161
|
+
'accept-encoding': 'gzip, deflate, br',
|
|
162
|
+
accept: 'application/json',
|
|
163
|
+
},
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
catch (e) {
|
|
167
|
+
logger_js_1.log.error('error', e);
|
|
168
|
+
throw e;
|
|
169
|
+
}
|
|
170
|
+
const data = await response.json();
|
|
171
|
+
if ('error_id' in data || Object.keys(data).length === 0) {
|
|
172
|
+
if (data.http_code == 401 || response.status == 401) {
|
|
173
|
+
throw new errors.BadApiKeyError(JSON.stringify(data));
|
|
174
|
+
}
|
|
175
|
+
throw new errors.ApiHttpClientError(JSON.stringify(data));
|
|
176
|
+
}
|
|
177
|
+
return data;
|
|
178
|
+
}
|
|
179
|
+
/**
|
|
180
|
+
* Issue a single scrape command from a given scrape configuration
|
|
181
|
+
*/
|
|
182
|
+
async scrape(config) {
|
|
183
|
+
logger_js_1.log.debug('scraping', { method: config.method, url: config.url });
|
|
184
|
+
let response;
|
|
185
|
+
try {
|
|
186
|
+
const url = new URL(this.HOST + '/scrape');
|
|
187
|
+
const params = config.toApiParams({ key: this.key });
|
|
188
|
+
url.search = new URLSearchParams(params).toString();
|
|
189
|
+
response = await this.fetch({
|
|
190
|
+
url: url.toString(),
|
|
191
|
+
method: config.method,
|
|
192
|
+
headers: {
|
|
193
|
+
'user-agent': this.ua,
|
|
194
|
+
'content-type': config.method === 'POST'
|
|
195
|
+
? config.headers?.['content-type'] ?? 'application/json'
|
|
196
|
+
: 'application/json',
|
|
197
|
+
'accept-encoding': 'gzip, deflate, br',
|
|
198
|
+
accept: 'application/json',
|
|
199
|
+
},
|
|
200
|
+
body: config.body,
|
|
201
|
+
});
|
|
202
|
+
}
|
|
203
|
+
catch (e) {
|
|
204
|
+
logger_js_1.log.error('error', e);
|
|
205
|
+
e.scrapeConfig = config;
|
|
206
|
+
throw e;
|
|
207
|
+
}
|
|
208
|
+
const data = await response.json();
|
|
209
|
+
if ('error_id' in data || Object.keys(data).length === 0) {
|
|
210
|
+
if (data.http_code == 401 || response.status == 401) {
|
|
211
|
+
throw new errors.BadApiKeyError(JSON.stringify(data));
|
|
212
|
+
}
|
|
213
|
+
throw new errors.ApiHttpClientError(JSON.stringify(data));
|
|
214
|
+
}
|
|
215
|
+
const result = this.handleResponse(response, new result_js_1.ScrapeResult({
|
|
216
|
+
config: data.config,
|
|
217
|
+
context: data.context,
|
|
218
|
+
result: data.result,
|
|
219
|
+
uuid: data.uuid,
|
|
220
|
+
}));
|
|
221
|
+
return result;
|
|
222
|
+
}
|
|
223
|
+
/**
|
|
224
|
+
Concurrently scrape multiple configs
|
|
225
|
+
This is a async generator call it like this:
|
|
226
|
+
|
|
227
|
+
const results = [];
|
|
228
|
+
const errors = [];
|
|
229
|
+
for await (const resultOrError of client.concurrentScrape(configs)) {
|
|
230
|
+
if (resultOrError instanceof Error) {
|
|
231
|
+
errors.push(resultOrError);
|
|
232
|
+
} else {
|
|
233
|
+
results.push(resultOrError);
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
@param concurrencyLimit: if not set it will be taken from your account info
|
|
238
|
+
*/
|
|
239
|
+
async *concurrentScrape(configs, concurrencyLimit) {
|
|
240
|
+
if (concurrencyLimit === undefined) {
|
|
241
|
+
const account = await this.account();
|
|
242
|
+
concurrencyLimit = account.subscription.usage.scrape.concurrent_limit;
|
|
243
|
+
logger_js_1.log.info(`concurrency not provided - setting it to ${concurrencyLimit} from account info`);
|
|
244
|
+
}
|
|
245
|
+
const activePromises = new Set();
|
|
246
|
+
const configsIterator = configs[Symbol.iterator]();
|
|
247
|
+
// Helper function to start a new scrape and add it to activePromises
|
|
248
|
+
const startNewScrape = () => {
|
|
249
|
+
const { value: config, done } = configsIterator.next();
|
|
250
|
+
if (done)
|
|
251
|
+
return; // No more configs
|
|
252
|
+
const promise = this.scrape(config).catch((error) => error); // Catch errors and return them
|
|
253
|
+
activePromises.add(promise);
|
|
254
|
+
promise.finally(() => {
|
|
255
|
+
activePromises.delete(promise);
|
|
256
|
+
// After each scrape, start a new one if there are remaining configs
|
|
257
|
+
startNewScrape();
|
|
258
|
+
});
|
|
259
|
+
};
|
|
260
|
+
// Initially start as many scrapes as the concurrency limit
|
|
261
|
+
for (let i = 0; i < concurrencyLimit; i++) {
|
|
262
|
+
startNewScrape();
|
|
263
|
+
}
|
|
264
|
+
// As each scrape finishes, yield the result or error and start a new one if there are remaining configs
|
|
265
|
+
while (activePromises.size > 0) {
|
|
266
|
+
logger_js_1.log.debug(`concurrently scraping ${activePromises.size}/${configs.length}}`);
|
|
267
|
+
const resultOrError = await Promise.race(activePromises);
|
|
268
|
+
yield resultOrError;
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
/**
|
|
272
|
+
* Save screenshot response to a file
|
|
273
|
+
*/
|
|
274
|
+
async saveScreenshot(result, name, savePath) {
|
|
275
|
+
if (!result.image) {
|
|
276
|
+
throw new Error('Screenshot binary does not exist');
|
|
277
|
+
}
|
|
278
|
+
const extension_name = result.metadata.extension_name;
|
|
279
|
+
let file_path;
|
|
280
|
+
if (savePath) {
|
|
281
|
+
await (0, polyfill_js_1.mkdir)(savePath, { recursive: true });
|
|
282
|
+
file_path = deps_js_1.path.join(savePath, `${name}.${extension_name}`);
|
|
283
|
+
}
|
|
284
|
+
else {
|
|
285
|
+
file_path = `${name}.${extension_name}`;
|
|
286
|
+
}
|
|
287
|
+
const content = new Uint8Array(result.image);
|
|
288
|
+
// Use Deno's write file method
|
|
289
|
+
await (0, polyfill_js_1.writeFile)(file_path, content);
|
|
290
|
+
}
|
|
291
|
+
/**
|
|
292
|
+
* Turn scrapfly screenshot API response to ScreenshotResult or raise one of ScrapflyError
|
|
293
|
+
*/
|
|
294
|
+
async handleScreenshotResponse(response) {
|
|
295
|
+
if (response.headers.get('content-type') === 'application/json') {
|
|
296
|
+
const data = (await response.json());
|
|
297
|
+
if (data.http_code == 401 || response.status == 401) {
|
|
298
|
+
throw new errors.BadApiKeyError(JSON.stringify(data));
|
|
299
|
+
}
|
|
300
|
+
if ('error_id' in data) {
|
|
301
|
+
throw new errors.ScreenshotApiError(JSON.stringify(data));
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
if (!response.ok) {
|
|
305
|
+
throw new errors.ScreenshotApiError(JSON.stringify(await response.json()));
|
|
306
|
+
}
|
|
307
|
+
const data = await response.arrayBuffer();
|
|
308
|
+
const result = new result_js_1.ScreenshotResult(response, data);
|
|
309
|
+
return result;
|
|
310
|
+
}
|
|
311
|
+
/**
|
|
312
|
+
* Take a screenshot
|
|
313
|
+
*/
|
|
314
|
+
async screenshot(config) {
|
|
315
|
+
let response;
|
|
316
|
+
try {
|
|
317
|
+
const url = new URL(this.HOST + '/screenshot');
|
|
318
|
+
const params = config.toApiParams({ key: this.key });
|
|
319
|
+
url.search = new URLSearchParams(params).toString();
|
|
320
|
+
response = await this.fetch({
|
|
321
|
+
url: url.toString(),
|
|
322
|
+
method: 'GET',
|
|
323
|
+
headers: {
|
|
324
|
+
'user-agent': this.ua,
|
|
325
|
+
'accept-encoding': 'gzip, deflate, br',
|
|
326
|
+
accept: 'application/json',
|
|
327
|
+
},
|
|
328
|
+
});
|
|
329
|
+
}
|
|
330
|
+
catch (e) {
|
|
331
|
+
logger_js_1.log.error('error', e);
|
|
332
|
+
throw e;
|
|
333
|
+
}
|
|
334
|
+
const result = await this.handleScreenshotResponse(response);
|
|
335
|
+
return result;
|
|
336
|
+
}
|
|
337
|
+
/**
|
|
338
|
+
* Turn scrapfly Extraction API response to ExtractionResult or raise one of ScrapflyError
|
|
339
|
+
*/
|
|
340
|
+
async handleExtractionResponse(response) {
|
|
341
|
+
const data = (await response.json());
|
|
342
|
+
if ('error_id' in data) {
|
|
343
|
+
if (data.http_code == 401 || response.status == 401) {
|
|
344
|
+
throw new errors.BadApiKeyError(JSON.stringify(data));
|
|
345
|
+
}
|
|
346
|
+
throw new errors.ExtractionApiError(JSON.stringify(data));
|
|
347
|
+
}
|
|
348
|
+
if (!response.ok) {
|
|
349
|
+
throw new errors.ApiHttpClientError(JSON.stringify(await response.json()));
|
|
350
|
+
}
|
|
351
|
+
const result = new result_js_1.ExtractionResult({
|
|
352
|
+
data: data.data,
|
|
353
|
+
content_type: data.content_type,
|
|
354
|
+
});
|
|
355
|
+
return result;
|
|
356
|
+
}
|
|
357
|
+
/**
|
|
358
|
+
* Extract structured data from a web page
|
|
359
|
+
*/
|
|
360
|
+
async extract(config) {
|
|
361
|
+
logger_js_1.log.debug('extacting data from', { content_type: config.content_type });
|
|
362
|
+
let response;
|
|
363
|
+
try {
|
|
364
|
+
const url = new URL(this.HOST + '/extraction');
|
|
365
|
+
const params = await config.toApiParams({ key: this.key });
|
|
366
|
+
url.search = new URLSearchParams(params).toString();
|
|
367
|
+
const headers = {
|
|
368
|
+
'user-agent': this.ua,
|
|
369
|
+
'accept-encoding': 'gzip, deflate, br',
|
|
370
|
+
'content-type': config.content_type,
|
|
371
|
+
'accept': 'application/json',
|
|
372
|
+
};
|
|
373
|
+
if (config.document_compression_format && config.document_compression_format) {
|
|
374
|
+
headers['content-encoding'] = config.document_compression_format;
|
|
375
|
+
}
|
|
376
|
+
response = await this.fetch({
|
|
377
|
+
url: url.toString(),
|
|
378
|
+
method: 'POST',
|
|
379
|
+
headers: headers,
|
|
380
|
+
body: config.body,
|
|
381
|
+
});
|
|
382
|
+
}
|
|
383
|
+
catch (e) {
|
|
384
|
+
logger_js_1.log.error('error', e);
|
|
385
|
+
throw e;
|
|
386
|
+
}
|
|
387
|
+
const result = await this.handleExtractionResponse(response);
|
|
388
|
+
return result;
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
exports.ScrapflyClient = ScrapflyClient;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"assert_path.d.ts","sourceRoot":"","sources":["../../../../../../../src/deps/jsr.io/@std/path/1.0.1/_common/assert_path.ts"],"names":[],"mappings":"AAGA,wBAAgB,UAAU,CAAC,IAAI,CAAC,EAAE,MAAM,QAMvC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
|
|
3
|
+
// Copyright the Browserify authors. MIT License.
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.assertPath = void 0;
|
|
6
|
+
function assertPath(path) {
|
|
7
|
+
if (typeof path !== "string") {
|
|
8
|
+
throw new TypeError(`Path must be a string. Received ${JSON.stringify(path)}`);
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
exports.assertPath = assertPath;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export declare function stripSuffix(name: string, suffix: string): string;
|
|
2
|
+
export declare function lastPathSegment(path: string, isSep: (char: number) => boolean, start?: number): string;
|
|
3
|
+
export declare function assertArgs(path: string, suffix: string): string | undefined;
|
|
4
|
+
//# sourceMappingURL=basename.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"basename.d.ts","sourceRoot":"","sources":["../../../../../../../src/deps/jsr.io/@std/path/1.0.1/_common/basename.ts"],"names":[],"mappings":"AAKA,wBAAgB,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM,CAchE;AAED,wBAAgB,eAAe,CAC7B,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,EAChC,KAAK,SAAI,GACR,MAAM,CAiBR;AAED,wBAAgB,UAAU,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,sBAQtD"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
|
|
3
|
+
// This module is browser compatible.
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.assertArgs = exports.lastPathSegment = exports.stripSuffix = void 0;
|
|
6
|
+
const assert_path_js_1 = require("./assert_path.js");
|
|
7
|
+
function stripSuffix(name, suffix) {
|
|
8
|
+
if (suffix.length >= name.length) {
|
|
9
|
+
return name;
|
|
10
|
+
}
|
|
11
|
+
const lenDiff = name.length - suffix.length;
|
|
12
|
+
for (let i = suffix.length - 1; i >= 0; --i) {
|
|
13
|
+
if (name.charCodeAt(lenDiff + i) !== suffix.charCodeAt(i)) {
|
|
14
|
+
return name;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
return name.slice(0, -suffix.length);
|
|
18
|
+
}
|
|
19
|
+
exports.stripSuffix = stripSuffix;
|
|
20
|
+
function lastPathSegment(path, isSep, start = 0) {
|
|
21
|
+
let matchedNonSeparator = false;
|
|
22
|
+
let end = path.length;
|
|
23
|
+
for (let i = path.length - 1; i >= start; --i) {
|
|
24
|
+
if (isSep(path.charCodeAt(i))) {
|
|
25
|
+
if (matchedNonSeparator) {
|
|
26
|
+
start = i + 1;
|
|
27
|
+
break;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
else if (!matchedNonSeparator) {
|
|
31
|
+
matchedNonSeparator = true;
|
|
32
|
+
end = i + 1;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
return path.slice(start, end);
|
|
36
|
+
}
|
|
37
|
+
exports.lastPathSegment = lastPathSegment;
|
|
38
|
+
function assertArgs(path, suffix) {
|
|
39
|
+
(0, assert_path_js_1.assertPath)(path);
|
|
40
|
+
if (path.length === 0)
|
|
41
|
+
return path;
|
|
42
|
+
if (typeof suffix !== "string") {
|
|
43
|
+
throw new TypeError(`Suffix must be a string. Received ${JSON.stringify(suffix)}`);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
exports.assertArgs = assertArgs;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../../../../../../../src/deps/jsr.io/@std/path/1.0.1/_common/common.ts"],"names":[],"mappings":"AAGA,wBAAgB,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,GAAG,MAAM,CAsB3D"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
|
|
3
|
+
// This module is browser compatible.
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.common = void 0;
|
|
6
|
+
function common(paths, sep) {
|
|
7
|
+
const [first = "", ...remaining] = paths;
|
|
8
|
+
const parts = first.split(sep);
|
|
9
|
+
let endOfPrefix = parts.length;
|
|
10
|
+
let append = "";
|
|
11
|
+
for (const path of remaining) {
|
|
12
|
+
const compare = path.split(sep);
|
|
13
|
+
if (compare.length <= endOfPrefix) {
|
|
14
|
+
endOfPrefix = compare.length;
|
|
15
|
+
append = "";
|
|
16
|
+
}
|
|
17
|
+
for (let i = 0; i < endOfPrefix; i++) {
|
|
18
|
+
if (compare[i] !== parts[i]) {
|
|
19
|
+
endOfPrefix = i;
|
|
20
|
+
append = i === 0 ? "" : sep;
|
|
21
|
+
break;
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
return parts.slice(0, endOfPrefix).join(sep) + append;
|
|
26
|
+
}
|
|
27
|
+
exports.common = common;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
export declare const CHAR_UPPERCASE_A = 65;
|
|
2
|
+
export declare const CHAR_LOWERCASE_A = 97;
|
|
3
|
+
export declare const CHAR_UPPERCASE_Z = 90;
|
|
4
|
+
export declare const CHAR_LOWERCASE_Z = 122;
|
|
5
|
+
export declare const CHAR_DOT = 46;
|
|
6
|
+
export declare const CHAR_FORWARD_SLASH = 47;
|
|
7
|
+
export declare const CHAR_BACKWARD_SLASH = 92;
|
|
8
|
+
export declare const CHAR_VERTICAL_LINE = 124;
|
|
9
|
+
export declare const CHAR_COLON = 58;
|
|
10
|
+
export declare const CHAR_QUESTION_MARK = 63;
|
|
11
|
+
export declare const CHAR_UNDERSCORE = 95;
|
|
12
|
+
export declare const CHAR_LINE_FEED = 10;
|
|
13
|
+
export declare const CHAR_CARRIAGE_RETURN = 13;
|
|
14
|
+
export declare const CHAR_TAB = 9;
|
|
15
|
+
export declare const CHAR_FORM_FEED = 12;
|
|
16
|
+
export declare const CHAR_EXCLAMATION_MARK = 33;
|
|
17
|
+
export declare const CHAR_HASH = 35;
|
|
18
|
+
export declare const CHAR_SPACE = 32;
|
|
19
|
+
export declare const CHAR_NO_BREAK_SPACE = 160;
|
|
20
|
+
export declare const CHAR_ZERO_WIDTH_NOBREAK_SPACE = 65279;
|
|
21
|
+
export declare const CHAR_LEFT_SQUARE_BRACKET = 91;
|
|
22
|
+
export declare const CHAR_RIGHT_SQUARE_BRACKET = 93;
|
|
23
|
+
export declare const CHAR_LEFT_ANGLE_BRACKET = 60;
|
|
24
|
+
export declare const CHAR_RIGHT_ANGLE_BRACKET = 62;
|
|
25
|
+
export declare const CHAR_LEFT_CURLY_BRACKET = 123;
|
|
26
|
+
export declare const CHAR_RIGHT_CURLY_BRACKET = 125;
|
|
27
|
+
export declare const CHAR_HYPHEN_MINUS = 45;
|
|
28
|
+
export declare const CHAR_PLUS = 43;
|
|
29
|
+
export declare const CHAR_DOUBLE_QUOTE = 34;
|
|
30
|
+
export declare const CHAR_SINGLE_QUOTE = 39;
|
|
31
|
+
export declare const CHAR_PERCENT = 37;
|
|
32
|
+
export declare const CHAR_SEMICOLON = 59;
|
|
33
|
+
export declare const CHAR_CIRCUMFLEX_ACCENT = 94;
|
|
34
|
+
export declare const CHAR_GRAVE_ACCENT = 96;
|
|
35
|
+
export declare const CHAR_AT = 64;
|
|
36
|
+
export declare const CHAR_AMPERSAND = 38;
|
|
37
|
+
export declare const CHAR_EQUAL = 61;
|
|
38
|
+
export declare const CHAR_0 = 48;
|
|
39
|
+
export declare const CHAR_9 = 57;
|
|
40
|
+
//# sourceMappingURL=constants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../../../src/deps/jsr.io/@std/path/1.0.1/_common/constants.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,gBAAgB,KAAK,CAAC;AACnC,eAAO,MAAM,gBAAgB,KAAK,CAAC;AACnC,eAAO,MAAM,gBAAgB,KAAK,CAAC;AACnC,eAAO,MAAM,gBAAgB,MAAM,CAAC;AAGpC,eAAO,MAAM,QAAQ,KAAK,CAAC;AAC3B,eAAO,MAAM,kBAAkB,KAAK,CAAC;AACrC,eAAO,MAAM,mBAAmB,KAAK,CAAC;AACtC,eAAO,MAAM,kBAAkB,MAAM,CAAC;AACtC,eAAO,MAAM,UAAU,KAAK,CAAC;AAC7B,eAAO,MAAM,kBAAkB,KAAK,CAAC;AACrC,eAAO,MAAM,eAAe,KAAK,CAAC;AAClC,eAAO,MAAM,cAAc,KAAK,CAAC;AACjC,eAAO,MAAM,oBAAoB,KAAK,CAAC;AACvC,eAAO,MAAM,QAAQ,IAAI,CAAC;AAC1B,eAAO,MAAM,cAAc,KAAK,CAAC;AACjC,eAAO,MAAM,qBAAqB,KAAK,CAAC;AACxC,eAAO,MAAM,SAAS,KAAK,CAAC;AAC5B,eAAO,MAAM,UAAU,KAAK,CAAC;AAC7B,eAAO,MAAM,mBAAmB,MAAM,CAAC;AACvC,eAAO,MAAM,6BAA6B,QAAQ,CAAC;AACnD,eAAO,MAAM,wBAAwB,KAAK,CAAC;AAC3C,eAAO,MAAM,yBAAyB,KAAK,CAAC;AAC5C,eAAO,MAAM,uBAAuB,KAAK,CAAC;AAC1C,eAAO,MAAM,wBAAwB,KAAK,CAAC;AAC3C,eAAO,MAAM,uBAAuB,MAAM,CAAC;AAC3C,eAAO,MAAM,wBAAwB,MAAM,CAAC;AAC5C,eAAO,MAAM,iBAAiB,KAAK,CAAC;AACpC,eAAO,MAAM,SAAS,KAAK,CAAC;AAC5B,eAAO,MAAM,iBAAiB,KAAK,CAAC;AACpC,eAAO,MAAM,iBAAiB,KAAK,CAAC;AACpC,eAAO,MAAM,YAAY,KAAK,CAAC;AAC/B,eAAO,MAAM,cAAc,KAAK,CAAC;AACjC,eAAO,MAAM,sBAAsB,KAAK,CAAC;AACzC,eAAO,MAAM,iBAAiB,KAAK,CAAC;AACpC,eAAO,MAAM,OAAO,KAAK,CAAC;AAC1B,eAAO,MAAM,cAAc,KAAK,CAAC;AACjC,eAAO,MAAM,UAAU,KAAK,CAAC;AAG7B,eAAO,MAAM,MAAM,KAAK,CAAC;AACzB,eAAO,MAAM,MAAM,KAAK,CAAC"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
|
|
3
|
+
// Copyright the Browserify authors. MIT License.
|
|
4
|
+
// Ported from https://github.com/browserify/path-browserify/
|
|
5
|
+
// This module is browser compatible.
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.CHAR_9 = exports.CHAR_0 = exports.CHAR_EQUAL = exports.CHAR_AMPERSAND = exports.CHAR_AT = exports.CHAR_GRAVE_ACCENT = exports.CHAR_CIRCUMFLEX_ACCENT = exports.CHAR_SEMICOLON = exports.CHAR_PERCENT = exports.CHAR_SINGLE_QUOTE = exports.CHAR_DOUBLE_QUOTE = exports.CHAR_PLUS = exports.CHAR_HYPHEN_MINUS = exports.CHAR_RIGHT_CURLY_BRACKET = exports.CHAR_LEFT_CURLY_BRACKET = exports.CHAR_RIGHT_ANGLE_BRACKET = exports.CHAR_LEFT_ANGLE_BRACKET = exports.CHAR_RIGHT_SQUARE_BRACKET = exports.CHAR_LEFT_SQUARE_BRACKET = exports.CHAR_ZERO_WIDTH_NOBREAK_SPACE = exports.CHAR_NO_BREAK_SPACE = exports.CHAR_SPACE = exports.CHAR_HASH = exports.CHAR_EXCLAMATION_MARK = exports.CHAR_FORM_FEED = exports.CHAR_TAB = exports.CHAR_CARRIAGE_RETURN = exports.CHAR_LINE_FEED = exports.CHAR_UNDERSCORE = exports.CHAR_QUESTION_MARK = exports.CHAR_COLON = exports.CHAR_VERTICAL_LINE = exports.CHAR_BACKWARD_SLASH = exports.CHAR_FORWARD_SLASH = exports.CHAR_DOT = exports.CHAR_LOWERCASE_Z = exports.CHAR_UPPERCASE_Z = exports.CHAR_LOWERCASE_A = exports.CHAR_UPPERCASE_A = void 0;
|
|
8
|
+
// Alphabet chars.
|
|
9
|
+
exports.CHAR_UPPERCASE_A = 65; /* A */
|
|
10
|
+
exports.CHAR_LOWERCASE_A = 97; /* a */
|
|
11
|
+
exports.CHAR_UPPERCASE_Z = 90; /* Z */
|
|
12
|
+
exports.CHAR_LOWERCASE_Z = 122; /* z */
|
|
13
|
+
// Non-alphabetic chars.
|
|
14
|
+
exports.CHAR_DOT = 46; /* . */
|
|
15
|
+
exports.CHAR_FORWARD_SLASH = 47; /* / */
|
|
16
|
+
exports.CHAR_BACKWARD_SLASH = 92; /* \ */
|
|
17
|
+
exports.CHAR_VERTICAL_LINE = 124; /* | */
|
|
18
|
+
exports.CHAR_COLON = 58; /* : */
|
|
19
|
+
exports.CHAR_QUESTION_MARK = 63; /* ? */
|
|
20
|
+
exports.CHAR_UNDERSCORE = 95; /* _ */
|
|
21
|
+
exports.CHAR_LINE_FEED = 10; /* \n */
|
|
22
|
+
exports.CHAR_CARRIAGE_RETURN = 13; /* \r */
|
|
23
|
+
exports.CHAR_TAB = 9; /* \t */
|
|
24
|
+
exports.CHAR_FORM_FEED = 12; /* \f */
|
|
25
|
+
exports.CHAR_EXCLAMATION_MARK = 33; /* ! */
|
|
26
|
+
exports.CHAR_HASH = 35; /* # */
|
|
27
|
+
exports.CHAR_SPACE = 32; /* */
|
|
28
|
+
exports.CHAR_NO_BREAK_SPACE = 160; /* \u00A0 */
|
|
29
|
+
exports.CHAR_ZERO_WIDTH_NOBREAK_SPACE = 65279; /* \uFEFF */
|
|
30
|
+
exports.CHAR_LEFT_SQUARE_BRACKET = 91; /* [ */
|
|
31
|
+
exports.CHAR_RIGHT_SQUARE_BRACKET = 93; /* ] */
|
|
32
|
+
exports.CHAR_LEFT_ANGLE_BRACKET = 60; /* < */
|
|
33
|
+
exports.CHAR_RIGHT_ANGLE_BRACKET = 62; /* > */
|
|
34
|
+
exports.CHAR_LEFT_CURLY_BRACKET = 123; /* { */
|
|
35
|
+
exports.CHAR_RIGHT_CURLY_BRACKET = 125; /* } */
|
|
36
|
+
exports.CHAR_HYPHEN_MINUS = 45; /* - */
|
|
37
|
+
exports.CHAR_PLUS = 43; /* + */
|
|
38
|
+
exports.CHAR_DOUBLE_QUOTE = 34; /* " */
|
|
39
|
+
exports.CHAR_SINGLE_QUOTE = 39; /* ' */
|
|
40
|
+
exports.CHAR_PERCENT = 37; /* % */
|
|
41
|
+
exports.CHAR_SEMICOLON = 59; /* ; */
|
|
42
|
+
exports.CHAR_CIRCUMFLEX_ACCENT = 94; /* ^ */
|
|
43
|
+
exports.CHAR_GRAVE_ACCENT = 96; /* ` */
|
|
44
|
+
exports.CHAR_AT = 64; /* @ */
|
|
45
|
+
exports.CHAR_AMPERSAND = 38; /* & */
|
|
46
|
+
exports.CHAR_EQUAL = 61; /* = */
|
|
47
|
+
// Digits
|
|
48
|
+
exports.CHAR_0 = 48; /* 0 */
|
|
49
|
+
exports.CHAR_9 = 57; /* 9 */
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dirname.d.ts","sourceRoot":"","sources":["../../../../../../../src/deps/jsr.io/@std/path/1.0.1/_common/dirname.ts"],"names":[],"mappings":"AAKA,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,mBAGrC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
|
|
3
|
+
// This module is browser compatible.
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.assertArg = void 0;
|
|
6
|
+
const assert_path_js_1 = require("./assert_path.js");
|
|
7
|
+
function assertArg(path) {
|
|
8
|
+
(0, assert_path_js_1.assertPath)(path);
|
|
9
|
+
if (path.length === 0)
|
|
10
|
+
return ".";
|
|
11
|
+
}
|
|
12
|
+
exports.assertArg = assertArg;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"format.d.ts","sourceRoot":"","sources":["../../../../../../../src/deps/jsr.io/@std/path/1.0.1/_common/format.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAE9C,wBAAgB,OAAO,CACrB,GAAG,EAAE,MAAM,EACX,UAAU,EAAE,OAAO,CAAC,UAAU,CAAC,GAC9B,MAAM,CAQR;AAED,wBAAgB,SAAS,CAAC,UAAU,EAAE,OAAO,CAAC,UAAU,CAAC,QAMxD"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
|
|
3
|
+
// This module is browser compatible.
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.assertArg = exports._format = void 0;
|
|
6
|
+
function _format(sep, pathObject) {
|
|
7
|
+
const dir = pathObject.dir || pathObject.root;
|
|
8
|
+
const base = pathObject.base ||
|
|
9
|
+
(pathObject.name || "") + (pathObject.ext || "");
|
|
10
|
+
if (!dir)
|
|
11
|
+
return base;
|
|
12
|
+
if (base === sep)
|
|
13
|
+
return dir;
|
|
14
|
+
if (dir === pathObject.root)
|
|
15
|
+
return dir + base;
|
|
16
|
+
return dir + sep + base;
|
|
17
|
+
}
|
|
18
|
+
exports._format = _format;
|
|
19
|
+
function assertArg(pathObject) {
|
|
20
|
+
if (pathObject === null || typeof pathObject !== "object") {
|
|
21
|
+
throw new TypeError(`The "pathObject" argument must be of type Object. Received type ${typeof pathObject}`);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
exports.assertArg = assertArg;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"from_file_url.d.ts","sourceRoot":"","sources":["../../../../../../../src/deps/jsr.io/@std/path/1.0.1/_common/from_file_url.ts"],"names":[],"mappings":";AAGA,wBAAgB,SAAS,CAAC,GAAG,EAAE,GAAG,GAAG,MAAM,OAM1C"}
|