@cocreate/file
Advanced tools
Comparing version 1.12.0 to 1.13.0
@@ -0,1 +1,13 @@ | ||
# [1.13.0](https://github.com/CoCreate-app/CoCreate-file/compare/v1.12.0...v1.13.0) (2023-11-25) | ||
### Bug Fixes | ||
* update nav, edit button and css path ([b88261d](https://github.com/CoCreate-app/CoCreate-file/commit/b88261df87594c7693a29cef287780d3ac44583b)) | ||
### Features | ||
* upgrade dependencies for latest features and fixes ([4fb4643](https://github.com/CoCreate-app/CoCreate-file/commit/4fb4643bdda0f7d3ca6fc09f95884e8703e92590)) | ||
# [1.12.0](https://github.com/CoCreate-app/CoCreate-file/compare/v1.11.0...v1.12.0) (2023-11-19) | ||
@@ -2,0 +14,0 @@ |
{ | ||
"name": "@cocreate/file", | ||
"version": "1.12.0", | ||
"version": "1.13.0", | ||
"description": "A headless file uploader that uses HTML5 attributes for customization. Allows easy upload of files to server.", | ||
@@ -62,7 +62,7 @@ "keywords": [ | ||
"dependencies": { | ||
"@cocreate/actions": "^1.12.4", | ||
"@cocreate/config": "^1.6.9", | ||
"@cocreate/render": "^1.32.0", | ||
"@cocreate/utils": "^1.27.4" | ||
"@cocreate/actions": "^1.13.0", | ||
"@cocreate/config": "^1.7.0", | ||
"@cocreate/render": "^1.34.0", | ||
"@cocreate/utils": "^1.28.0" | ||
} | ||
} |
@@ -36,8 +36,14 @@ /******************************************************************************** | ||
/** | ||
* Initializes file elements. If no parameter is provided, it queries and initializes all elements with type="file". | ||
* It can also initialize a single element or an array of elements. Specifically focuses on elements of type 'file'. | ||
* | ||
* @param {(Element|Element[]|null)} [elements] - Optional. An element, an array of elements, or null. | ||
* - If null or omitted, the function queries and initializes all elements in the document with type="file". | ||
* - If a single element is provided, it initializes that element (assuming it is of type "file"). | ||
* - If an array of elements is provided, each element in the array is initialized. | ||
*/ | ||
function init(elements) { | ||
// Returns an array of elements. | ||
if (!elements) | ||
elements = document.querySelectorAll('[type="file"]') | ||
// If elements is an not array of elements returns an array of elements. | ||
else if (!Array.isArray(elements)) | ||
@@ -44,0 +50,0 @@ elements = [elements] |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
133512
1160
Updated@cocreate/actions@^1.13.0
Updated@cocreate/config@^1.7.0
Updated@cocreate/render@^1.34.0
Updated@cocreate/utils@^1.28.0