feat(COMPONENT): Add Possibility to stop Page Change on Paginator
- Ngôn ngữ chính
- TypeScript
- Star
- 25k
- Fork
- 6.8k
- Merge trung bình
- 1 ngày 8 giờ
- Pull request đã merge (30 ngày)
- 91
Mô tả
### Feature Description
Currently when you press any button on the paginator the page is changed and the PageEvent is emitted afterwards.
It would be great to be able to intercept the pageEvent before it is done and maybe call something like `event.stopPropagation()` and or `event.preventDefault()`
### Use Case
There is no way of stopping the page change for example if you would want to implement a dialog which confirms if the user wants to lose their changes made on the current page. (Especially when the paginator is not connected to the table and the pagination is used for the backend)
Here is a [stackblitz](https://stackblitz.com/edit/pbfhnu68-qn7l5mng?file=src%2Fexample%2Ftable-pagination-example.html) that shows the problem.
Hướng dẫn đóng góp
Hướng nghiên cứu
Bắt đầu bằng cách tái hiện hành vi của paginator trong StackBlitz được liên kết và theo dõi thời điểm PageEvent được phát ra so với lúc thay đổi trang. Xác định cách một thao tác chặn sớm cần báo hiệu việc hủy, sau đó kiểm tra rằng một điều hướng đã được xác nhận vẫn thay đổi trang và phát ra sự kiện như mong đợi.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- angular, typescript
- Lĩnh vực
- frontend
- Loại issue
- Tính năng
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100