feat: Enhance gallery functionality with lightbox feature and improve icon sprite accessibility
- Added a lightbox feature for gallery images, allowing users to view photos in a modal with navigation controls. - Updated the SVG sprite to include inline styles for better accessibility. - Increased CSS specificity by doubling the `.vc-app` class to ensure styles override Astra theme defaults. - Introduced new shortcodes for bus tours, about section, and articles in the VC_Sections class. - Improved the handling of featured images in the single tour template for sharper display. - Updated version number to 1.8.15.
This commit is contained in:
@@ -16,23 +16,31 @@ listing/single/section assets load only on pages that use them.
|
||||
| `[viator_top_tours]` | Rail of tour cards | `viator_tour` posts |
|
||||
| `[viator_top_attractions]` | Rail of tour cards | `viator_tour` posts |
|
||||
| `[viator_browse_activities]` | Rail of tour cards | `viator_tour` posts |
|
||||
| `[viator_bus_tours]` | "Open Top Bus Tours" promo + 4-up card grid | `viator_tour` posts |
|
||||
| `[viator_about]` | Static "About / Memorable" block + stat counters | Shortcode attributes |
|
||||
| `[viator_articles]` | Rail of latest blog-post cards | `post` posts |
|
||||
| `[viator_faq]` | FAQ accordion | Shortcode `items` / `vc_faq_items` filter |
|
||||
| `[viator_testimonials]` | Testimonials marquee | `vc_testimonials` filter |
|
||||
|
||||
`[viator_hero_slider]` is kept as a **back-compat alias** for `[viator_hero]`.
|
||||
|
||||
A typical home page:
|
||||
Home page matching the design mockup (`new front/index.html`), top to bottom:
|
||||
|
||||
```
|
||||
[viator_hero]
|
||||
[viator_hero image_id="125304"]
|
||||
[viator_top_destinations]
|
||||
[viator_bus_tours image_id="125310"]
|
||||
[viator_top_tours]
|
||||
[viator_top_attractions]
|
||||
[viator_browse_activities]
|
||||
[viator_about image_id="125311"]
|
||||
[viator_testimonials]
|
||||
[viator_articles]
|
||||
[viator_faq]
|
||||
```
|
||||
|
||||
Heavy decorative images (hero photo, open-top bus, isometric bus) are **not
|
||||
bundled** — upload them in **Media** and pass the attachment `image_id` (exactly
|
||||
like `[viator_hero image_id="…"]`). Icons and tiny decorations are inline SVG.
|
||||
|
||||
---
|
||||
|
||||
## `[viator_hero]`
|
||||
@@ -99,6 +107,71 @@ are hidden automatically.
|
||||
|
||||
---
|
||||
|
||||
## `[viator_bus_tours]`
|
||||
|
||||
The "Open Top Bus Tours…" promo block (route line, headline, "See all", a chip,
|
||||
a bus illustration and note) followed by a 4-up grid of tour cards. Selects tours
|
||||
with the **same attributes as the tour rails** (`ids` / `codes` / `destination` /
|
||||
`tag` / `limit` / `orderby`), plus:
|
||||
|
||||
| Attribute | Default | Description |
|
||||
|---|---|---|
|
||||
| `title` | `Open Top<br>Bus Tours…` | Promo headline (`<br>` allowed). |
|
||||
| `note` | *(default copy)* | Paragraph under the headline. |
|
||||
| `chip` | `Very Fun!` | Small accent chip. |
|
||||
| `image_id` | — | **Media attachment ID** of the open-top bus illustration. |
|
||||
| `image` | — | …or a direct image URL (use `image_id` when possible). |
|
||||
|
||||
```
|
||||
[viator_bus_tours image_id="125310" tag="hop-on-hop-off" limit="4"]
|
||||
[viator_bus_tours ids="482,517,690,701"]
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## `[viator_about]`
|
||||
|
||||
Static "About" marketing block: headline with an accent chip, a paragraph, four
|
||||
stat counters and a decorative isometric bus. All copy is editable.
|
||||
|
||||
| Attribute | Default | Description |
|
||||
|---|---|---|
|
||||
| `title` | `Hop On Hop Off` | Headline. |
|
||||
| `highlight` | `Memorable` | Accent chip appended to the headline. |
|
||||
| `text` | *(default copy)* | Paragraph. |
|
||||
| `button_text` | `About us` | Button label. |
|
||||
| `button_url` | *(tours archive)* | Button link. |
|
||||
| `image_id` | — | **Media attachment ID** of the isometric bus illustration. |
|
||||
| `image` | — | …or a direct image URL. |
|
||||
| `stats` | *(4 defaults)* | `25+|Years Experience;;500+|Tours Conducted` — `|` separates number from label, `;;` separates stats. A trailing `+` is styled. |
|
||||
|
||||
```
|
||||
[viator_about image_id="125311" stats="25+|Years Experience;;500+|Tours Conducted;;430+|Tours this Year;;15+|Different Tours"]
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## `[viator_articles]`
|
||||
|
||||
A rail of the latest blog posts styled as the design's "Latest Articles" cards
|
||||
(featured image, relative time, title, excerpt → links to the post).
|
||||
|
||||
| Attribute | Default | Description |
|
||||
|---|---|---|
|
||||
| `title` | `Latest<br>Articles` | Heading (`<br>` allowed). |
|
||||
| `lead` | *(default copy)* | Sub-heading. |
|
||||
| `limit` | `8` | Number of posts. |
|
||||
| `category` | — | Restrict to a category slug. |
|
||||
| `view_all` | *(posts page)* | "See all" link; defaults to the blog page. |
|
||||
|
||||
Cards use each post's **featured image**; set one so the card isn't blank.
|
||||
|
||||
```
|
||||
[viator_articles limit="8" category="travel-tips"]
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## `[viator_faq]`
|
||||
|
||||
FAQ accordion.
|
||||
|
||||
Reference in New Issue
Block a user