import{isPoint as e}from"../../utilities/esri.js";import{isSubtypeSublayer as r}from"../../utilities/layers.js";import{ClientSideIdentifyProvider as t}from"./ClientSideIdentifyProvider.js";export class SubtypeSublayerClientSideIdentifyProvider extends t{isSupported(t,i,s){return r(t?.sublayer)&&t.sublayer.layer&&t.layerExtension.enableClientSideData&&i&&!!t.layerExtension._layerView?.view?.extent?.intersects(e(i)?i:i.extent)}_createQuery(e,r,t,i){const s=super._createQuery(e,r,t,i),{subtypeField:l}=e.sublayer.layer,y=e.sublayer.subtypeCode;return l&&(s.where=`${l}=${y}`),s}}