github / github/app

Let canvas extensions capture the exact pixels shown in a browser preview

Đang mở
#3,184 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
triage
Ngôn ngữ chính
Không có dữ liệu ngôn ngữ
Star
2.1k
Fork
153
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

### Feature summary

screenshot API for canvas extensions

### What problem are you trying to solve?

Today, an extension can inspect or rebuild the page, but it cannot capture the actual rendered preview. Rebuilding it from the DOM gives different results for responsive layouts, fonts, canvas, video, WebGL, embedded content, and browser-rendered effects.

### Proposed solution

Could the canvas provide a screenshot API that:
- Captures the visible preview exactly as rendered.
- Uses the current viewport size and device pixel ratio.
- Captures compositor output instead of rebuilding the DOM.
- Returns a PNG or blob to the extension.
- Only gives an extension access to its own canvas.

I only need the visible preview, not a full-page screenshot or the surrounding Copilot UI. This would make visual annotation reliable and framework-independent.

### Workflow impact

_No response_

### Installation context

_No response_

### Additional context

_No response_

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Hướng nghiên cứu

Không có tệp, bài kiểm thử hoặc entry point nào được nêu. Hãy bắt đầu bằng cách xác định extension của canvas và phần triển khai bản xem trước trên trình duyệt, sau đó lần theo cách đầu ra compositor hiển thị được tạo ra; công việc được xem là hoàn tất khi một API có phạm vi giới hạn có thể trả về ảnh chụp màn hình viewport chính xác ở kích thước hiện tại và device pixel ratio hiện tại mà không để lộ UI xung quanh.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Lĩnh vực
frontend
Loại issue
Tính năng
Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức độ hoạt động
Sôi nổi
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
35/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.