{
    "description": {
        "author": "Salesforce",
        "text": [
            "Selector: UVMContainer.",
            "Represents the iOS Landing page for the Offline App.",
            "Verify the components seen on Landing page."
        ]
    },
    "implements": "utam-salesforceapp/pageObjects/offlineapp/landingPage",
    "root": true,
    "exposeRootElement": true,
    "platform": "native",
    "profile": [
        {
            "platform": [
                "ios_phone",
                "ios_tablet"
            ]
        }
    ],
    "selector": {
        "accessid": "UVMContainer"
    },
    "beforeLoad": [
        {
            "apply": "waitFor",
            "args": [
                {
                    "type": "function",
                    "predicate": [
                        {
                            "element": "root",
                            "apply": "isPresent"
                        },
                        {
                            "element": "root",
                            "apply": "containsElement",
                            "args": [
                                {
                                    "type": "locator",
                                    "value": {
                                        "accessid": "briefcase_summary"
                                    }
                                }
                            ]
                        }
                    ]
                }
            ]
        }
    ],
    "elements": [
        {
            "name": "cardWithName",
            "type": "utam-salesforceapp/pageObjects/offlineapp/landingPageCard",
            "selector": {
                "accessid": "%s",
                "args": [
                    {
                        "name": "cardName",
                        "type": "string"
                    }
                ]
            },
            "public": true
        },
        {
            "name": "cards",
            "type": "utam-salesforceapp/pageObjects/offlineapp/landingPageCard",
            "public": true,
            "selector": {
                "classchain": "**/XCUIElementTypeOther[`name CONTAINS 'card_'`]",
                "returnAll": true
            }
        },
        {
            "name": "briefcaseSummary",
            "type": "utam-salesforceapp/pageObjects/offlineapp/briefcaseSummary",
            "public": true,
            "selector": {
                "accessid": "briefcase_summary"
            }
        },
        {
            "name": "draftSummary",
            "type": "utam-salesforceapp/pageObjects/offlineapp/draftSummary",
            "public": true,
            "selector": {
                "accessid": "draft_status"
            }
        }
    ],
    "methods": [
        {
            "name": "hasCardWithName",
            "compose": [
                {
                    "returnType": "boolean",
                    "element": "cardWithName",
                    "matcher": {
                        "type": "notNull"
                    }
                }
            ]
        },
        {
            "name": "hasDraftSummary",
            "compose": [
                {
                    "element": "root",
                    "apply": "containsElement",
                    "args": [
                        {
                            "type": "locator",
                            "value": {
                                "accessid": "draft_status"
                            }
                        }
                    ]
                }
            ]
        }
    ]
}