title: Python Playwright, Select last item question
body: <p>I need to automate grabbing something from first column and something from last column.</p>
  <p>The trouble relays that all of the items have the same area to click</p>
  <pre><code>&lt;div _ngcontent-fse-c5=&quot;&quot; class=&quot;battle-status ng-star-inserted&quot; data-test-id=&quot;selectForBattleButton&quot;&gt; Select for battle &lt;/div&gt;            
  </code></pre>
  <p>they are nested on</p>
  <pre><code>&lt;app-cat-card _ngcontent-fse-c3=&quot;&quot; _nghost-fse-c5=&quot;&quot; ng-reflect-cat=&quot;[object Object]&quot; ng-reflect-did-cat-fight=&quot;false&quot; ng-reflect-selectable=&quot;true&quot; ng-reflect-should-show-success-overlay=&quot;false&quot; ng-reflect-should-show-failure-overlay=&quot;false&quot; data-test-id=&quot;cat_1&quot; class=&quot;ng-star-inserted&quot;&gt;&lt;div _ngcontent-fse-c5=&quot;&quot; data-test-id=&quot;catCard&quot; class=&quot;cat-card&quot;&gt;&lt;img _ngcontent-fse-c5=&quot;&quot; class=&quot;cat-avatar&quot; src=&quot;https://robohash.org/flexible-stuart.png&quot;&gt;&lt;div _ngcontent-fse-c5=&quot;&quot; class=&quot;cat-details&quot;&gt;&lt;p _ngcontent-fse-c5=&quot;&quot; class=&quot;cat-name&quot;&gt;Flexible Stuart&lt;/p&gt;&lt;p _ngcontent-fse-c5=&quot;&quot;&gt;&lt;b _ngcontent-fse-c5=&quot;&quot;&gt;Power move:&lt;/b&gt; Searching Swan &lt;br _ngcontent-fse-c5=&quot;&quot;&gt;&lt;b _ngcontent-fse-c5=&quot;&quot;&gt;Experience level:&lt;/b&gt; 10 &lt;/p&gt;&lt;!--bindings={
    &quot;ng-reflect-ng-if&quot;: &quot;true&quot;
  }--&gt;&lt;div _ngcontent-fse-c5=&quot;&quot; class=&quot;ng-star-inserted&quot;&gt;&lt;!--bindings={
    &quot;ng-reflect-ng-if&quot;: &quot;true&quot;
  }--&gt;&lt;div _ngcontent-fse-c5=&quot;&quot; class=&quot;battle-status ng-star-inserted&quot; data-test-id=&quot;selectForBattleButton&quot;&gt; Select for battle &lt;/div&gt;&lt;!--bindings={
    &quot;ng-reflect-ng-if&quot;: &quot;false&quot;
  }--&gt;&lt;/div&gt;&lt;!--bindings={
    &quot;ng-reflect-ng-if&quot;: &quot;false&quot;
  }--&gt;&lt;!--bindings={
    &quot;ng-reflect-ng-if&quot;: &quot;false&quot;
  }--&gt;&lt;/div&gt;&lt;/div&gt;&lt;/app-cat-card&gt;
  </code></pre>
  <p>It is my first time using <strong>playwright</strong> and could use a clue or assistance.</p>
  <p>I have tried</p>
  <pre><code>page.click(&quot;text=Select for Battle &quot;)
  </code></pre>
  <p>to click the first but if i do it again the second one gets clicked and if i do it again the first is selected again.</p>
  <p>Any ideas are welcome.</p>