- Full-Stack Vue.js 2 and Laravel 5
- Anthony Gore
- 162字
- 2021-07-02 19:57:22
Image modal window
To prevent our header image from dominating the page, we've cropped it and limited its height. But what if the user wants to see the image in its full glory? A great UI design pattern to allow the user to focus on a single item of content is amodal window.
Here's what our modal will look like when opened:

Figure 2.10. Header image modal
Our modal will give a properly scaled view of the header image so the user can focus on the appearance of the lodgings without the distraction of the rest of the page.
Later in the book, we will insert an image carousel into the modal so the user can browse through a whole collection of room images!
For now, though, here are the required features for our modal:
- Open the modal by clicking the header image
- Freeze the main window
- Show the image
- Close the modal window with a close button or the Escape key
推薦閱讀
- 基于粒計算模型的圖像處理
- Deploying Node.js
- Getting Started with PowerShell
- 數(shù)據(jù)結(jié)構(gòu)(Python語言描述)(第2版)
- 你必須知道的204個Visual C++開發(fā)問題
- 零基礎(chǔ)入門學(xué)習(xí)Python(第2版)
- Instant Lucene.NET
- Django 3.0入門與實踐
- R數(shù)據(jù)科學(xué)實戰(zhàn):工具詳解與案例分析
- jQuery技術(shù)內(nèi)幕:深入解析jQuery架構(gòu)設(shè)計與實現(xiàn)原理
- C語言程序設(shè)計
- Go語言入門經(jīng)典
- C語言程序設(shè)計實踐
- UML基礎(chǔ)與Rose建模實用教程(第三版)
- 深入大型數(shù)據(jù)集:并行與分布化Python代碼