"use strict";(self.webpackChunktradingview=self.webpackChunktradingview||[]).push([[1754],{89324:(e,t,o)=>{o.r(t),o.d(t,{Components:()=>h,showDefaultSearchDialog:()=>c,showSymbolSearchItemsDialog:()=>l.showSymbolSearchItemsDialog});var a=o(29803),s=(o(32563),o(4745)),n=o(48961),l=o(1861),i=o(22613),r=o(84015);o(37103),o(49483);!(0,r.isOnMobileAppPage)("any")&&window.matchMedia("(min-width: 602px) and (min-height: 445px)").matches;function c(e){new i.WatchedValue({});const t=(0,n.getSymbolSearchCompleteOverrideFunction)(),{defaultValue:o,showSpreadActions:r,source:c,onSearchComplete:h,trackResultsOptions:d,...m}=e,u={...m,showSpreadActions:r??(0,s.canShowSpreadActions)(),onSymbolFiltersParamsChange:void 0,onSearchComplete:(e,o)=>{t(e[0].symbol,e[0].result).then((e=>{a.linking.setSymbolAndLogInitiator(e.symbol,"symbol search"),h?.(e.symbol)}))},onEmptyResults:void 0};(0,l.showSymbolSearchItemsDialog)({...u,defaultValue:o})}const h={SymbolSearchWatchlistDialogContentItem:null,SymbolSearchWatchlistDialog:null}},1861:(e,t,o)=>{o.d(t,{showSymbolSearchItemsDialog:()=>r});var a=o(50959),s=o(50655),n=o(51826),l=o(59071),i=o(87896);function r(e){const{symbolTypeFilter:t,initialMode:o="symbolSearch",autofocus:r=!0,defaultValue:c,showSpreadActions:h,selectSearchOnInit:d,onSearchComplete:m,dialogTitle:u,placeholder:S,fullscreen:g,initialScreen:p,wrapper:y,dialog:b,contentItem:w,onClose:C,onOpen:f,footer:O,symbolTypes:I,searchInput:v,emptyState:M,hideMarkedListFlag:D,dialogWidth:F="auto",manager:R,shouldReturnFocus:A,onSymbolFiltersParamsChange:P,onEmptyResults:k,customSearchSymbols:V,enableOptionsChain:E,disableRecents:T,overrideQueryParams:W,hiddenFilterIds:_,showRecents:K,searchInitiationPoint:x,selectedSymbolSettingsKey:L,filterValuesSettingsKey:Q}=e;if(n.dialogsOpenerManager.isOpened("SymbolSearch")||n.dialogsOpenerManager.isOpened("ChangeIntervalDialog"))return;const j=document.createElement("div"),q=a.createElement(s.SlotContext.Provider,{value:R??null},a.createElement(l.SymbolSearchItemsDialog,{symbolTypeFilter:t,onClose:B,initialMode:o,defaultValue:c,showSpreadActions:h,hideMarkedListFlag:D,selectSearchOnInit:d,onSearchComplete:m,dialogTitle:u,placeholder:S,fullscreen:g,initialScreen:p,wrapper:y,dialog:b,contentItem:w,footer:O,symbolTypes:I,searchInput:v,emptyState:M,autofocus:r,dialogWidth:F,shouldReturnFocus:A,onSymbolFiltersParamsChange:P,onEmptyResults:k,customSearchSymbols:V,enableOptionsChain:E,disableRecents:T,overrideQueryParams:W,hiddenFilterIds:_,showRecents:K,searchInitiationPoint:x,selectedSymbolSettingsKey:L,filterValuesSettingsKey:Q})),z=(0,i.createReactRoot)(q,j);function B(){z.unmount(),n.dialogsOpenerManager.setAsClosed("SymbolSearch"),C&&C()}return n.dialogsOpenerManager.setAsOpened("SymbolSearch"),f&&f(),{close:B}}},51826:(e,t,o)=>{o.d(t,{DialogsOpenerManager:()=>a,dialogsOpenerManager:()=>s});class a{constructor(){this._storage=new Map}setAsOpened(e,t){this._storage.set(e,t)}setAsClosed(e){this._storage.delete(e)}isOpened(e){return this._storage.has(e)}getDialogPayload(e){return this._storage.get(e)}}
const s=new a}}]);