Does the specification define input[type=file] .files expected behaviour to relevant to reflecting real-time changes to user selected file?
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Cần làm rõ
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- html, javascript
Hướng nghiên cứu
Xem xét các định nghĩa của File API cho File và FileList, sau đó so sánh các yêu cầu của chúng với bản tái hiện Stack Overflow được liên kết và các quan sát trên Chromium 65 và Firefox Trunk. Công việc được xem là hoàn tất khi xác định được liệu các thay đổi sau khi chọn đối với kích thước và lastModified của một tệp cục bộ có phải được phản ánh hay không, đồng thời tài liệu hóa hoặc làm rõ đặc tả tương ứng.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Consider the HTML and JavaScript posted at this Stack Overflow question Input file size and content do not update on macOS
HTML
<!DOCTYPE html>
<input type="file" id="file" />
<p id="info"></p>
JavaScript
window.addEventListener('load', function() {
window.setInterval(function() {
var logFile = document.querySelector('#file').files[0];
if (logFile) {
document.querySelector('#info').innerHTML = '<br/>' +
(new Date()).toString() + '<br/>Last modified: ' +
logFile.lastModified +
'<br/>Size: ' +
logFile.size;
}
}, 1000);
});
Reproduce steps as described by OP of the question
Please test with following snippet. Select a file (for example a text file), see last modified timestamp and file size, then change file and look again, if size has changed. On macOS the file size doesn't change.
Using a sample file, for example, https://gist.github.com/guest271314/11edc4566ba94f204dd46e6ae26edaad#file-d134213ba9465cb74dfd36cde47bf102638c4a9f3aca357f79ee747dd5f49f1e0f0de , which contains the text
123
Behaviour
Chromium 65
Once the local file is selected by user action and the local file is changed at a text editor, for example, by typing 4 following the existing 123 at the file (for example, the above linked gist) both lastModified and size properties are reflected as being changed client side, indicating changes to local file are being updated in real time though the user has not performed the affirmative action of re-selecting the file.
Firefox Trunk (60)
Once the local file is selected by user action and the local file is changed at a text editor, for example, by typing 4 following the existing 123 at the file (for example, the above linked gist) both lastModified and size properties are not reflected as being changed client side, indicating changes to local file are being not updated in real time where the user has not performed the affirmative action of re-selecting the file.
What does the specification define as the expected behaviour of size and lastModified properties of a File object within a FileList object where changes to an underlying local file are made after user selection of a local file?
- Ngôn ngữ chính
- HTML
- Star
- 118
- Fork
- 52
- Merge trung bình
- 9 ngày 16 giờ
- Pull request đã merge (30 ngày)
- 1
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của w3c/FileAPI
-
TPAC 2026 Status Report Đang mởTPAC2026
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
-
Broken references in File API Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 62/100
-
Add accessibility section Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 30/100
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
use-agent-os/agent-os#3276 ·
-
good first issue refactor
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
-
[6.x]: "Cannot use object of type stdClass as array" loading Users index (regression of #19182) Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 90/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
-
area/sessions comp/agent P2 tool/skills type/perf
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
NousResearch/hermes-agent#117788 ·