Cannot Get Data from Model Popup

Hello everyone.
I have one use-case where I'm not sure how to handle it.

  1. Full description, more images and some other more custom type of data is hidden under a button
  2. When I click those respective buttons for each option I get a popup with more info. From there I need to get the texts like Description from description model, Amenities from amenities model and images from images popup.

How would you tackle this ?

thanks!

Url: Rent in Murooj Al Furjan West: BRAND NEW VILLA | PRIVATE POOL | 5BED ROOM | Property Finder

Sitemap:
{"_id":"testing","startUrl":["https://www.propertyfinder.ae/en/plp/rent/villa-for-rent-dubai-al-furjan-murooj-al-furjan-west-13320493.html"],"selectors":[{"id":"Description","parentSelectors":["_root"],"type":"SelectorElementClick","clickActionType":"real","clickElementSelector":"button.styles_button__nN08_","clickElementUniquenessType":"uniqueText","clickType":"clickOnce","delay":200,"discardInitialElements":"do-not-discard","multiple":true,"selector":"div.styles_desktop_navigable-section__Zqa_u"},{"id":"Amenities","parentSelectors":["_root"],"type":"SelectorElementClick","clickActionType":"real","clickElementSelector":".styles_amenity__container__kL4sm button","clickElementUniquenessType":"uniqueText","clickType":"clickOnce","delay":200,"discardInitialElements":"do-not-discard","multiple":true,"selector":"div.styles_desktop_content--left__8d5Tu"},{"id":"Images","parentSelectors":["_root"],"type":"SelectorElementClick","clickActionType":"real","clickElementSelector":"button.styles_desktop_button__BgEkL","clickElementUniquenessType":"uniqueText","clickType":"clickOnce","delay":200,"discardInitialElements":"do-not-discard","multiple":true,"selector":"button.styles-module_gallery-thumbnails__list__item__G9-ki:nth-of-type(n+2)"}]}

easy...

{"_id":"testing","startUrl":["https://www.propertyfinder.ae/en/plp/rent/villa-for-rent-dubai-al-furjan-murooj-al-furjan-west-13320493.html"],"selectors":[{"id":"Description","multiple":false,"parentSelectors":["_root"],"regex":"","selector":"[data-testid=\"description-section\"]","type":"SelectorText"},{"extractAttribute":"","id":"Amenities","parentSelectors":["_root"],"selector":"[class*=\"styles_amenity__container\"] p","type":"SelectorGroup"},{"clickActionType":"real","clickElementSelector":"button[data-testid=\"gallery-image-button\"]","clickElementUniquenessType":"uniqueCSSSelector","clickType":"clickOnce","delay":1500,"discardInitialElements":"discard","id":"click","multiple":false,"parentSelectors":["_root"],"selector":"button[data-testid=\"gallery-image-button\"]","type":"SelectorElementClick"},{"clickActionType":"real","clickElementSelector":"button[data-testid=\"gallery-thumbnail-0\"]","clickElementUniquenessType":"uniqueCSSSelector","clickType":"clickOnce","delay":500,"discardInitialElements":"discard","id":"click2","multiple":false,"parentSelectors":["_root"],"selector":"button[data-testid=\"gallery-thumbnail-0\"]","type":"SelectorElementClick"},{"extractAttribute":"src","id":"Images","parentSelectors":["_root"],"selector":"[data-testid=\"gallery-item\"] img","type":"SelectorGroup"}]}
1 Like

Thank you so much for this solution.
It has one problem only -> it did not scrape all amenities and skipped that are only visible on popup.

some changes performed... please check it

{"_id":"testing","startUrl":["https://www.propertyfinder.ae/en/plp/rent/villa-for-rent-dubai-al-furjan-murooj-al-furjan-west-13320493.html"],"selectors":[{"id":"Description","multiple":false,"parentSelectors":["_root"],"regex":"","selector":"[data-testid=\"description-section\"] article","type":"SelectorText"},{"clickActionType":"real","clickElementSelector":"button:contains(\"See all amenities\")","clickElementUniquenessType":"uniqueCSSSelector","clickType":"clickOnce","delay":500,"discardInitialElements":"discard","id":"click_am","multiple":false,"parentSelectors":["_root"],"selector":"body","type":"SelectorElementClick"},{"extractAttribute":"","id":"Amenities","parentSelectors":["_root"],"selector":"[data-testid=\"modal-body\"] div[class*=\"amenity__container\"] p","type":"SelectorGroup"},{"clickActionType":"real","clickElementSelector":"button[data-testid=\"gallery-image-button\"]","clickElementUniquenessType":"uniqueCSSSelector","clickType":"clickOnce","delay":1500,"discardInitialElements":"discard","id":"click","multiple":false,"parentSelectors":["_root"],"selector":"button[data-testid=\"gallery-image-button\"]","type":"SelectorElementClick"},{"clickActionType":"real","clickElementSelector":"button[data-testid=\"gallery-thumbnail-0\"]","clickElementUniquenessType":"uniqueCSSSelector","clickType":"clickOnce","delay":500,"discardInitialElements":"discard","id":"click2","multiple":false,"parentSelectors":["_root"],"selector":"button[data-testid=\"gallery-thumbnail-0\"]","type":"SelectorElementClick"},{"extractAttribute":"src","id":"Images","parentSelectors":["_root"],"selector":"[data-testid=\"gallery-item\"] img","type":"SelectorGroup"}]}