一千萬個為什麽

搜索

是否可以在可回流的EPUB3中創建側邊欄?



有沒有一種方法可以在EPUB3中創建響應式側邊欄,例如,在平板電腦視圖中會有一個側欄,但如果在移動設備上查看EPUB,它會變成一列?

轉載註明原文: 是否可以在可回流的EPUB3中創建側邊欄?

一共有 2 個回答:

大多數epub閱讀系統不響應媒體查詢,所以它會被擊中或錯過。您可以嘗試在CSS中首先放置側邊欄樣式,以便在不理解媒體查詢的系統中級聯,邊欄樣式將被更一般的列樣式覆蓋,但不能保證它能正常工作。

即使在平板電腦上,側欄也可能在高字體大小時出現問題:就像表格一樣,如果側邊欄的末尾不適合當前頁面,它將不會繼續到下一頁 - 它會從底部運行屏幕。

我認為這絕對有可能 - 特別是在ibooks,Kindle和Google Play(可能還有其他一些)。 (請參閱本文有關編寫媒體查詢以區分不同設備: https ://medium.com/@sandersk/responsive-ebook-design-a-primer-8bba01328219

接下來的問題就是:小型顯示器應該是什麽樣的電子書?你需要有一個側邊欄?

大量的側邊欄內容可以制作成一個塊,而不是內聯元素。奧雷利的書有很多這些說明性的框,讀者習慣將它們與文本分開閱讀。

The most common use for sidebars (for me at least) was inserting an inline graphic or a pullquote. With high resolution displays, inline graphics are now doable but as recently as 2 years ago it made little sense to include a graphic if it takes up 40% of screen width because the text to the side of it looked awful. My problem with putting graphics in sidebars is that I couldn't figure out if whether Android devices required low resolution graphics or whether -- like Kindle -- accepted high res graphics which it would downconvert depending on the intended device. (See my still unanswered question here: Interior Image requirements for non-Kindle distributors & devices with retina displays? )