1. 程式人生 > >(翻譯)分頁模式(Pagination)

(翻譯)分頁模式(Pagination)

問題概述

  使用者要檢視資料集合的部分內容,且資料集合以可理解的方式進行排列[1]。

示例

這裡寫圖片描述

用途

  • 用於不適合在一個頁面/螢幕中顯示所有資料時;
  • 用於資料集合以某種方式排列時;
  • 如果不想在切換到下一頁內容時暫停使用者動作,不要使用本模式[2]。

解決方案

  將完整的資料集合拆分為較小的有序資料子集,為每個資料子集提供獨立的連結。
  使用分頁控制元件瀏覽不同的頁面,提供連結讓使用者瀏覽上一頁及下一頁,還提供到第一頁和最後一頁的連結。
  如果資料集合大小已知,則顯示到最後一頁的連結,否則不顯示。

說明

  將大資料集合劃分為小的資料子集,降低感知複雜性,便於使用者進行內容瀏覽管控。僅返回全部資料的部分子集,極大提高技術效能。[3]
  首要的,本模式將大資料集合劃分為小的資料子集,便於使用者讀取和處理。其次,使用者可以從分頁控制元件中瞭解資料集合有多大、還剩多少內容沒看、已經看了多少內容。
  本模式自然地中斷使用者的內容瀏覽行為,讓使用者重新考慮是否接著瀏覽更多內容還是離開當前頁面。這也是分頁控制元件經常放在列表下的原因,給使用者一個選擇,是否繼續瀏覽大資料集合中的內容。[4]

原文地址:http://ui-patterns.com/patterns/Pagination
[1]原文:The user needs to view a subset of sorted data in a comprehensible form
[2]原文:Do not use when you don’t want the user to pause for navigating to the next page.
[3]原文:Reduce perceived complexity by parting large datasets into smaller chunks that are more manageable for the user. Significant technical performance can be achieved by only having to return subsets of the overall data.
[4]原文:Pagination provides the user with a natural break from reading or scanning the contents of the dataset, and allows them to re-evaluate whether they wish to continue looking through more data, or navigate away from the page. This is also why pagination controls are most often placed below the list: to provide the user with an option to continue reading through the larger dataset.