@ytsaurus/ui 2.4.0 → 2.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,2 +0,0 @@
1
- "use strict";(self.webpackChunk_ytsaurus_ui=self.webpackChunk_ytsaurus_ui||[]).push([[2789],{11896:(e,t,n)=>{n.d(t,{c:()=>i});var i={CLUSTER_PARAMS:"CLUSTER_PARAMS",ACCOUNTS:"ACCOUNTS_",NAVIGATION_PRELOAD:"NAVIGATION_PRELOAD",NAVIGATION_CONTENT_DOCUMENT:"NAVIGATION_CONTENT_DOCUMENT",NAVIGATION_CONTENT_FILE:"NAVIGATION_CONTENT_FILE",NAVIGATION_CONTENT_LINK:"NAVIGATION_CONTENT_LINK",NAVIGATION_CONTENT_MAP_NODE:"NAVIGATION_CONTENT_MAP_NODE_",NAVIGATION_CONTENT_REPLICATED_TABLE:"NAVIGATION_CONTENT_REPLICATED_TABLE",NAVIGATION_CONTENT_TABLE_STATIC:"NAVIGATION_CONTENT_TABLE_STATIC",NAVIGATION_CONTENT_TABLE_DYNAMIC:"NAVIGATION_CONTENT_TABLE_DYNAMIC",NAVIGATION_CONTENT_TRANSACTION:"NAVIGATION_CONTENT_TRANSACTION",NAVIGATION_CONTENT_TRANSACTION_MAP:"NAVIGATION_CONTENT_TRANSACTION_MAP",NAVIGATION_TAB_ACL:"NAVIGATION_TAB_ACL",NAVIGATION_TAB_ACL_ACCESS:"NAVIGATION_TAB_ACL_ACCESS",NAVIGATION_TAB_ANNOTATION:"NAVIGATION_TAB_ANNOTATION",NAVIGATION_TAB_ATTRIBUTES:"NAVIGATION_TAB_ATTRIBUTES",NAVIGATION_TAB_USER_ATTRIBUTES:"NAVIGATION_TAB_USER_ATTRIBUTES",NAVIGATION_TAB_LOCKS:"NAVIGATION_TAB_LOCKS",NAVIGATION_TAB_SCHEMA:"NAVIGATION_TAB_SCHEMA",NAVIGATION_TAB_TABLETS:"NAVIGATION_TAB_TABLETS",NAVIGATION_TAB_TABLET_ERRORS:"NAVIGATION_TAB_TABLET_ERRORS",OPERATIONS_LIST:"OPERATIONS_LIST_",OPERATION:"OPERATION",OPERATION_TAB_DETAILS:"OPERATION_TAB_DETAILS",OPERATION_TAB_ATTRIBUTES:"OPERATION_TAB_ATTRIBUTES",OPERATION_TAB_SPECIFICATION:"OPERATION_TAB_SPECIFICATION",OPERATION_TAB_STATISTICS:"OPERATION_TAB_STATISTICS",OPERATION_TAB_MONITOR:"OPERATION_TAB_MONITOR",OPERATION_TAB_PARTITION_SIZES:"OPERATION_TAB_PARTITION_SIZES",OPERATION_TAB_JOB_SIZES:"OPERATION_TAB_JOB_SIZES",OPERATION_TAB_JOBS:"OPERATION_TAB_JOBS",SCHEDULING:"SCHEDULING_",SCHEDULING_OVERVIEW:"SCHEDULING_OVERVIEW",SCHEDULING_DETAILS:"SCHEDULING_DETAILS",SCHEDULING_MONITOR:"SCHEDULING_MONITOR",SCHEDULING_ACL:"SCHEDULING_ACL",YQL_KIT_WIDGET:"YQL_KIT_WIDGET"}},16865:(e,t,n)=>{n.r(t),n.d(t,{default:()=>Xt});var i=n(77810),s=n(76872),r=n(27528),o=n.n(r),a=n(17239),l=n.n(a),c=n(34072),u=n(32235),d=n(62167),g=n(24893),p=n(5865),m=n(70243),h=n(54487),f=n(73457),_=n(31816),A=n(37338),v=n(72890),N=n(89648),T=n(6542),E=(0,A.N)({en:{button_close:"Close"},ru:{button_close:"Закрыть"}},`${h.N}Title`);(0,f.s)(".gn-title{align-items:center;box-sizing:border-box;display:flex;justify-content:space-between;min-height:64px;padding:14px 10px 14px 20px}.gn-title_separator{border-bottom:1px solid var(--g-color-line-generic)}.gn-title__text{margin:0 20px 0 0}");const O=(0,h.b)("title"),S=({children:e,closeIconSize:t=23,hasSeparator:n,closeTitle:s=E("button_close"),onClose:r})=>i.createElement("div",{className:O({separator:n})},i.createElement(N.E,{className:O("text"),as:"h3",variant:"subheader-3"},e),r&&i.createElement(T.$,{onClick:r,view:"flat",size:"l",extraProps:{"aria-label":s}},i.createElement(u.I,{data:v.A,size:t})));function b(e){const t=i.useRef();return i.useEffect((()=>(t.current=e,()=>{t.current=void 0})),[e]),i.useCallback(((...e)=>{if("function"==typeof t.current)return t.current(...e)}),[])}function x(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function I(e,t=""){const n=x(t).replace(/\s+/g,".*?");return w(e,"",new RegExp(n,"i"))}function w(e,t="",n){const s=[],r={};let o=!1,a=!1;return i.Children.forEach(e,(e=>{var l,c;if(i.isValidElement(e))if(e.type===i.Fragment){const{menu:i,pages:o}=w(e.props.children,t,n);s.push(...i),Object.assign(r,o)}else if(e.props.groupTitle){const i=`${t}/${null!==(l=e.props.id)&&void 0!==l?l:e.props.groupTitle}`;o=!0;const{menu:a,pages:c}=w(e.props.children,i,n);s.push({groupTitle:e.props.groupTitle,items:a}),Object.assign(r,c)}else{a=!0;const i=`${t}/${null!==(c=e.props.id)&&void 0!==c?c:e.props.title}`;r[i]=y(e.props.children,n),r[i].id=i,s.push({id:i,title:e.props.title,icon:e.props.icon,withBadge:r[i].withBadge,disabled:r[i].hidden})}})),{menu:s,pages:r}}function y(e,t){const n={id:"",sections:[],hidden:!0};return i.Children.forEach(e,(e=>{if(i.isValidElement(e))if(e.type===i.Fragment){const{sections:i,withBadge:s,hidden:r}=y(e.props.children,t);n.sections.push(...i),n.withBadge=s||n.withBadge,n.hidden=r&&n.hidden}else{const{withBadge:i,showTitle:s=!0}=e.props,{items:r,hidden:o}=C(e.props.children,t);n.withBadge=i||n.withBadge,n.hidden=o&&n.hidden,n.sections.push(Object.assign(Object.assign({},e.props),{withBadge:i,items:r,hidden:o,showTitle:s}))}})),n}function C(e,t){let n=!0;const s=[];return i.Children.forEach(e,(e=>{if(i.isValidElement(e))if(e.type===i.Fragment){const i=C(e.props.children,t);s.push(...i.items),n=n&&i.hidden}else{const i=Object.assign(Object.assign({},e.props),{element:e,hidden:!t.test(e.props.title)});s.push(i),n=n&&i.hidden}})),{items:s,hidden:n}}S.displayName="Title";const R=i.createContext({});R.displayName="SettingsSelectionContext";const L=R.Provider;var j=function(e){return e};(0,f.s)('.gn-settings-menu__group-heading{display:inline-block;font-weight:var(--g-text-accent-font-weight);line-height:18px;margin-bottom:12px;padding:0 20px}.gn-settings-menu__group+.gn-settings-menu__group{margin-top:24px}.gn-settings-menu__item{align-items:center;color:var(--g-color-text-primary);cursor:pointer;display:flex;height:40px;padding:0 20px}.gn-settings-menu__item-icon{color:var(--g-color-text-misc);margin-right:5px}.gn-settings-menu__item:hover,.gn-settings-menu__item_focused{background:var(--g-color-base-simple-hover)}.gn-settings-menu__item_selected{background:var(--g-color-base-selection)}.gn-settings-menu__item_selected.gn-settings-menu__item_focused,.gn-settings-menu__item_selected:hover{background:var(--g-color-base-selection-hover)}.gn-settings-menu__item_disabled{color:var(--g-color-text-secondary);cursor:auto}.gn-settings-menu__item_disabled:hover{background:none}.gn-settings-menu__item_disabled .gn-settings-menu__item-icon{color:var(--g-color-base-misc-heavy)}.gn-settings-menu__item_badge{position:relative}.gn-settings-menu__item_badge:after{background-color:var(--g-color-text-danger);border-radius:50%;content:"";display:block;height:6px;position:absolute;right:9px;top:calc(50% - 3px);width:6px}');const V=(0,h.b)("settings-menu"),G=i.forwardRef((function({items:e,onChange:t,activeItemId:n},s){const[r,o]=i.useState(),a=i.useRef(null),l=b(t),c=function(e){const t=i.useRef(e);return t.current=e,i.useCallback((()=>t.current),[])}(r);return i.useImperativeHandle(s,(()=>({handleKeyDown(e){if(!a.current)return!1;const t=c();return t&&"Enter"===e.key?(l(t),!0):"ArrowDown"===e.key?(o(B(a.current,t,1)),!0):"ArrowUp"===e.key&&(o(B(a.current,t,-1)),!0)},clearFocus(){o(void 0)}})),[c,l]),i.createElement("div",{ref:a,className:V()},e.map((e=>"groupTitle"in e?i.createElement("div",{key:e.groupTitle,className:V("group")},i.createElement("span",{className:V("group-heading")},e.groupTitle),e.items.map((e=>k(e,t,n,r)))):k(e,t,n,r))))}));function k(e,t,n,s){return i.createElement("span",{key:e.title,className:V("item",{selected:n===e.id,disabled:e.disabled,focused:s===e.id,badge:e.withBadge}),onClick:()=>{e.disabled||t(e.id)},"data-id":e.id},e.icon?i.createElement(u.I,Object.assign({size:16},e.icon,{className:V("item-icon")})):void 0,i.createElement("span",null,e.title))}function B(e,t,n){var i;const s=e.querySelectorAll(`.${V("item")}:not(.${V("item")}_disabled)`);if(0===s.length)return;let r=n>0?-1:0;return t&&(r=Array.prototype.findIndex.call(s,(e=>e.getAttribute("data-id")===t))),r=(s.length+r+n)%s.length,null!==(i=s[r].getAttribute("data-id"))&&void 0!==i?i:void 0}(0,f.s)('.gn-settings-menu-mobile.g-tabs_direction_horizontal{-ms-overflow-style:none;flex-wrap:nowrap;overflow-x:auto;overscroll-behavior-x:none;scrollbar-width:none}.gn-settings-menu-mobile.g-tabs_direction_horizontal::-webkit-scrollbar{display:none}.gn-settings-menu-mobile__item_badge{position:relative}.gn-settings-menu-mobile__item_badge:after{background-color:var(--g-color-text-danger);border-radius:50%;content:"";display:block;height:6px;position:absolute;right:-8px;top:11px;width:6px}');const P=(0,h.b)("settings-menu-mobile"),U=({items:e,onChange:t,activeItemId:n,className:s})=>{const r=i.useRef(null),o=i.useMemo((()=>{const t=[];return e.forEach((e=>{if("groupTitle"in e)t.push(...e.items.map((({id:e,title:t,disabled:n,withBadge:i})=>({id:e,title:t,disabled:n,className:P("item",{badge:i})}))));else{const{id:n,title:i,disabled:s,withBadge:r}=e;t.push({id:n,title:i,disabled:s,className:P("item",{badge:r})})}})),t}),[e]);return i.createElement("div",{ref:r,onTouchMove:e=>{e.stopPropagation()}},i.createElement(d.t,{items:o,className:P(null,s),size:"l",activeTab:n,onSelectTab:t}))};var M=(0,A.N)({en:{label_title:"Settings","label_filter-placeholder":"Search settings","label_empty-placeholder":"No results found",label_search:"Search"},ru:{label_title:"Настройки","label_filter-placeholder":"Найти настройки","label_empty-placeholder":"Ничего не найдено",label_search:"Поиск"}},`${h.N}Settings`);const D=(0,h.b)("settings-search");function F({className:e,initialValue:t,onChange:n,debounce:s=200,inputRef:r,inputSize:o,placeholder:a,autoFocus:l=!0}){const[c,u]=i.useState(null!=t?t:""),d=b((0,_.d)(n,s)),p=b((e=>{u(e),d(e)}));return i.createElement("div",{className:D(null,e)},i.createElement(g.k,{value:c,controlRef:r,hasClear:!0,autoFocus:l,size:o,placeholder:a,onUpdate:p,controlProps:{"aria-label":M("label_search")}}))}(0,f.s)('.gn-settings{display:grid;grid-template-columns:216px 1fr;height:100%;width:834px}.gn-settings_view_mobile{display:block;height:calc(80vh - 56px);overflow-x:hidden;width:auto}@supports (height:90dvh){.gn-settings_view_mobile{height:calc(90dvh - 56px)}}.gn-settings_view_mobile.gn-settings_loading{text-align:center}.gn-settings_view_mobile .gn-settings__loader{margin-top:20px}.gn-settings_view_mobile .gn-settings__search{margin:4px 0 16px;padding:0 20px}.gn-settings_view_mobile .gn-settings__page{overflow-y:visible}.gn-settings_view_mobile .gn-settings__tabs .g-tabs__item:first-child{margin-left:20px}.gn-settings_view_mobile .gn-settings__tabs .g-tabs__item:last-child{margin-right:20px}.gn-settings_view_mobile .gn-settings__section-heading{font-size:var(--g-text-subheader-3-font-size);font-weight:var(--g-text-subheader-font-weight);line-height:var(--g-text-subheader-3-line-height)}.gn-settings_view_mobile .gn-settings__section-subheader{color:var(--g-color-text-secondary)}.gn-settings_view_mobile .gn-settings__section-heading+.gn-settings-subheader{margin-top:8px}.gn-settings_view_mobile .gn-settings__section-item{margin-top:0}.gn-settings_view_mobile .gn-settings__section-heading+.gn-settings__section-item,.gn-settings_view_mobile .gn-settings__section-subheader+.gn-settings__section-item{margin-top:30px}.gn-settings_view_mobile .gn-settings__section-item+.gn-settings__section-item{margin-top:22px}.gn-settings_view_mobile .gn-settings__item:not(.gn-settings_view_mobile .gn-settings__item_mode_row){gap:8px;grid-template-columns:1fr}.gn-settings_view_mobile .gn-settings__item-heading{font-size:var(--g-text-body-2-font-size);font-weight:var(--g-text-body-font-weight);line-height:var(--g-text-body-2-line-height)}.gn-settings_view_mobile .gn-settings__item-description{font-size:var(--g-text-body-1-font-size);font-weight:var(--g-text-body-font-weight);line-height:var(--g-text-body-1-line-height)}.gn-settings_view_mobile .gn-settings__item_mode_row{grid-template-columns:1fr auto}.gn-settings_view_mobile .gn-settings__item_mode_row .gn-settings__item-heading{padding-right:20px}.gn-settings_view_mobile .gn-settings__item-content{width:100%}.gn-settings_view_mobile .gn-settings__not-found{color:var(--g-color-text-hint);font-size:var(--g-text-body-2-font-size);font-weight:var(--g-text-body-font-weight);justify-items:start;line-height:var(--g-text-body-2-line-height);margin:20px 0 0 20px}.gn-settings_loading{grid-template-columns:auto}.gn-settings__loader{place-self:center}.gn-settings__not-found{display:grid;height:100%;place-items:center}.gn-settings__menu{border-right:1px solid var(--g-color-line-generic)}.gn-settings__heading{font-size:var(--g-text-subheader-2-font-size);font-weight:var(--g-text-subheader-font-weight);line-height:var(--g-text-subheader-2-line-height);margin:20px 20px 0}.gn-settings__search{margin:0 20px 16px}.gn-settings__page{overflow-y:auto}.gn-settings__content{padding:20px}.gn-settings__section-right-adornment_hidden{opacity:0;transition:opacity .2s}.gn-settings__section-heading:hover .gn-settings__section-right-adornment_hidden{opacity:1}.gn-settings__section-heading{font-size:var(--g-text-subheader-2-font-size);font-weight:var(--g-text-subheader-font-weight);line-height:var(--g-text-subheader-2-line-height);margin:0}.gn-settings__section-item{margin-top:24px}.gn-settings__section+.gn-settings__section{margin-top:32px}.gn-settings__item{display:grid;grid-template-columns:216px 1fr;justify-items:start}.gn-settings__item_align_top{align-items:start}.gn-settings__item_align_center{align-items:center}.gn-settings__item-title_badge{position:relative}.gn-settings__item-title_badge:after{background-color:var(--g-color-text-danger);border-radius:50%;content:"";display:block;height:6px;position:absolute;right:-8px;top:1px;width:6px}.gn-settings__item-description{color:var(--g-color-text-secondary);display:block;font-size:var(--g-text-caption-2-font-size);font-weight:var(--g-text-caption-font-weight);line-height:var(--g-text-caption-2-line-height);margin-top:2px;padding-right:20px}.gn-settings__item-right-adornment_hidden{opacity:0;transition:opacity .2s}.gn-settings__item:hover .gn-settings__item-right-adornment_hidden{opacity:1}.gn-settings__item_selected,.gn-settings__section_selected{background:var(--g-color-base-selection);border-radius:8px;margin-left:-8px;padding:8px}.gn-settings__found{background:var(--g-color-base-selection);font-weight:var(--g-text-accent-font-weight)}');const H=(0,h.b)("settings"),z=i.createContext({}),K=()=>i.useContext(z);function Y(e){var{loading:t,renderLoading:n,children:s,view:r="normal",renderRightAdornment:o,renderSectionRightAdornment:a,showRightAdornmentOnHover:l=!0}=e,u=(0,c._)(e,["loading","renderLoading","children","view","renderRightAdornment","renderSectionRightAdornment","showRightAdornmentOnHover"]);return t?i.createElement("div",{className:H({loading:!0,view:r})},"function"==typeof n?n():i.createElement(p.a,{className:H("loader"),size:"m"})):i.createElement(z.Provider,{value:{renderRightAdornment:o,renderSectionRightAdornment:a,showRightAdornmentOnHover:l}},i.createElement(Q,Object.assign({view:r},u),s))}const q=(e,t)=>{for(const n of e)if("groupTitle"in n){for(const e of n.items)if(e.id===t)return e.title}else if(n.id===t)return n.title;return""};function Q({initialPage:e,initialSearch:t,selection:n,children:s,renderNotFound:r,title:o=M("label_title"),filterPlaceholder:a=M("label_filter-placeholder"),emptyPlaceholder:l=M("label_empty-placeholder"),view:c,onPageChange:u,onClose:d}){var g,p;const{renderSectionRightAdornment:h,showRightAdornmentOnHover:f}=K(),[_,A]=i.useState(null!=t?t:""),{menu:v,pages:N}=I(s,_),T=function(e,t){const n=i.useRef(null);return i.useMemo((()=>t?Object.assign({selectedRef:n},function(e,t){if(!t.settingId&&!t.section&&!t.page)return{};for(const n of Object.values(e)){if(!t.settingId&&!t.section){if(t.page!==n.id)continue;return{page:n}}for(const e of n.sections)if(t.settingId){for(const i of e.items)if(i.id===t.settingId)return{page:n,section:e,setting:i}}else if(t.section&&("id"in t.section?t.section.id===e.id:t.section.title===e.title))return{page:n,section:e}}return{}}(e,t)):{selectedRef:n}),[e,t])}(N,n),E=Object.keys(N),O=T.page&&E.includes(T.page.id)?T.page.id:void 0,[b,x]=i.useState(O||(e&&E.includes(e)?e:void 0)),w=i.useRef(null),y=i.useRef(null),C="mobile"===c;i.useEffect((()=>{var e;null===(e=y.current)||void 0===e||e.clearFocus()}),[_]),i.useEffect((()=>{const e=()=>{var e;null===(e=y.current)||void 0===e||e.clearFocus()};return window.addEventListener("click",e),()=>{window.removeEventListener("click",e)}}),[]);let R=b;R&&!(null===(g=N[R])||void 0===g?void 0:g.hidden)||(R=null===(p=Object.values(N).find((({hidden:e})=>!e)))||void 0===p?void 0:p.id);const j=e=>{x((t=>(t!==e&&(null==u||u(e)),e)))};i.useEffect((()=>{R!==b&&j(R)})),i.useEffect((()=>{O&&x(O)}),[O]),i.useEffect((()=>{var e;(null===(e=T.selectedRef)||void 0===e?void 0:e.current)&&T.selectedRef.current.scrollIntoView()}),[T.selectedRef]);return i.createElement(L,{value:T},i.createElement("div",{className:H({view:c})},C?i.createElement(i.Fragment,null,i.createElement(F,{inputRef:w,className:H("search"),initialValue:t,onChange:A,autoFocus:!1,inputSize:"xl"}),i.createElement(U,{items:v,onChange:j,activeItemId:R,className:H("tabs")})):i.createElement("div",{className:H("menu"),onClick:()=>{w.current&&w.current.focus()},onKeyDown:e=>{y.current&&y.current.handleKeyDown(e)&&e.preventDefault()}},i.createElement(S,null,o),i.createElement(F,{inputRef:w,className:H("search"),initialValue:t,onChange:A,placeholder:a,autoFocus:!0}),i.createElement(G,{ref:y,items:v,onChange:j,activeItemId:R})),i.createElement("div",{className:H("page")},(e=>{if(!e)return"function"==typeof r?r():i.createElement("div",{className:H("not-found")},l);const t=N[e].sections.filter((e=>!e.hidden));return i.createElement(i.Fragment,null,!C&&i.createElement(S,{hasSeparator:!0,onClose:d},q(v,e)),i.createElement("div",{className:H("content")},t.map((t=>((e,t)=>{const n=function(e,t,n){var i;return!(!e.section||e.setting||(!e.section.id||e.section.id!==n.id)&&((null===(i=e.page)||void 0===i?void 0:i.id)!==t||!e.section.title||e.section.title!==n.title))}(T,e,t);return i.createElement("div",{key:t.title,className:H("section",{selected:n}),ref:n?T.selectedRef:void 0},t.showTitle&&i.createElement("h3",{className:H("section-heading")},h?i.createElement(m.s,{gap:2,alignItems:"center"},t.title,i.createElement("div",{className:H("section-right-adornment",{hidden:f})},h(t))):t.title),t.header&&(C?i.createElement("div",{className:H("section-subheader")},t.header):t.header),t.items.map((e=>e.hidden?null:(({title:e,element:t})=>i.createElement("div",{key:e,className:H("section-item")},i.cloneElement(t,Object.assign(Object.assign({},t.props),{highlightedTitle:_&&e?W(e,_):e}))))(e))))})(e,t)))))})(R))))}function W(e,t){let n=e.slice(0);const s=[],r=x(t).split(" ").filter(Boolean);let o=0;for(const e of r){const t=new RegExp(e,"ig").exec(n);if(t){const e=t[0],r=t.index;r>0&&s.push(n.slice(0,r)),s.push(i.createElement("strong",{key:o++,className:H("found")},e)),n=n.slice(r+e.length)}}return n&&s.push(n),s}Y.Group=function({children:e}){return i.createElement(i.Fragment,null,e)},Y.Page=function({children:e}){return i.createElement(i.Fragment,null,e)},Y.Section=function({children:e}){return i.createElement(i.Fragment,null,e)},Y.Item=function(e){const{id:t,labelId:n,highlightedTitle:s,children:r,align:o="center",withBadge:a,renderTitleComponent:l=j,mode:c,description:u}=e,d=i.useContext(R),g=d.setting&&d.setting.id===t,{renderRightAdornment:p,showRightAdornmentOnHover:h}=K(),f=i.createElement("span",{className:H("item-title",{badge:a})},l(s));return i.createElement("div",{className:H("item",{align:o,mode:c,selected:g}),ref:g?d.selectedRef:void 0},i.createElement("label",{className:H("item-heading"),id:n},p?i.createElement(m.s,{className:H("item-title-wrapper"),gap:3},f,i.createElement("div",{className:H("item-right-adornment",{hidden:h})},p(e))):f,u?i.createElement("span",{className:H("item-description")},u):null),i.createElement("div",{className:H("item-content")},r))};var J=n(13322),$=n(15647),Z=n(29347),X=n.n(Z),ee=n(49214),te=n.n(ee),ne=n(39760),ie=n.n(ne),se=n(75414),re=n.n(se),oe=n(79184),ae=n(7787),le=n(40319),ce=n(64922);const ue=function(e){return(0,ce.jsxs)("svg",(0,le.A)((0,le.A)({xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 16 16"},e),{},{children:[(0,ce.jsx)("path",{fillRule:"evenodd",d:"m.115 2.124 3.119 4.442 1.713-.365 3.721 3.72c-.095.237-.17.507-.191.8-.041.59.148 1.206.684 1.75l2.89 2.94c.254.26.549.423.866.484.311.06.59.012.805-.063a1.9 1.9 0 0 0 .672-.41l.015-.014.005-.006.808-.807.001-.002.002-.002.006-.006.015-.015a2 2 0 0 0 .148-.18 1.9 1.9 0 0 0 .261-.491c.075-.216.124-.494.064-.805a1.65 1.65 0 0 0-.484-.867l-2.94-2.89c-.545-.535-1.16-.724-1.75-.684-.293.02-.564.097-.8.192l-3.72-3.722.365-1.713L1.948.292zm9.858 8.701c.011-.157.07-.33.164-.511.182-.094.354-.153.512-.164.162-.011.356.023.595.257l2.94 2.89a.3.3 0 0 1 .062.08l-.007.028a.4.4 0 0 1-.079.13l-.801.801a.4.4 0 0 1-.159.086.3.3 0 0 1-.08-.062l-2.89-2.94c-.234-.238-.268-.433-.257-.595M3.891 4.892l.68-.145.145-.68-2.599-1.824-.05.05z",clipRule:"evenodd"}),(0,ce.jsx)("path",{fillRule:"evenodd",d:"m9.764 6.809 2.815.385 1.7-1.701-.042.162c-.21.735-.61 1.482-1.054 1.926a3.1 3.1 0 0 1-.697.525l1.082 1.1q.348-.237.658-.547c1.342-1.342 2.034-3.997 1.39-4.661a1.36 1.36 0 0 0-1.946-.016l-1.615 1.614-1.046-.143-.241-1.186 1.615-1.615c.542-.542.549-1.428.016-1.979C11.755.01 9.132.67 7.79 2.01a4.7 4.7 0 0 0-.823 1.112l1.124 1.141c.152-.43.4-.833.742-1.175.444-.444 1.186-.839 1.912-1.04l.16-.04-1.759 1.758z",clipRule:"evenodd"}),(0,ce.jsx)("path",{d:"m4.62 7.81.079-.076 1.054 1.072a1 1 0 0 0-.08.074l-3.275 3.329a1.275 1.275 0 0 0 0 1.782c.484.492 1.269.492 1.753 0l3.17-3.222.4 1.732-2.518 2.56a2.696 2.696 0 0 1-3.857 0 2.804 2.804 0 0 1 0-3.921z"})]}))},de=function(e){return(0,ce.jsx)("svg",(0,le.A)((0,le.A)({xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 16 16"},e),{},{children:(0,ce.jsx)("path",{d:"M5 8c0 .563-.469 1-1 1-.562 0-1-.437-1-1 0-.531.438-1 1-1 .531 0 1 .469 1 1M4 5c0-.531.438-1 1-1 .531 0 1 .469 1 1 0 .563-.469 1-1 1-.562 0-1-.437-1-1m5-1c0 .563-.469 1-1 1-.562 0-1-.437-1-1 0-.531.438-1 1-1 .531 0 1 .469 1 1m1 1c0-.531.438-1 1-1 .531 0 1 .469 1 1 0 .563-.469 1-1 1-.562 0-1-.437-1-1m3.781 5H10.75a1.5 1.5 0 0 0-1.5 1.5c0 .125 0 .219.031.313.063.343.188.624.313.937.187.438.406.875.406 1.313 0 1-.687 1.906-1.687 1.937H8c-4.437 0-8-3.562-8-8 0-4.406 3.563-8 8-8 4.406 0 8 3.594 8 8 0 .031-.031.063-.031.094C15.969 9.25 14.938 10 13.78 10m.688-1.906c0-.031.031-.063.031-.094 0-3.562-2.937-6.5-6.5-6.5-3.594 0-6.5 2.938-6.5 6.5 0 3.594 2.906 6.5 6.5 6.5h.313l.062-.062c.063-.063.125-.188.125-.376 0-.03-.031-.156-.187-.53-.032-.032-.032-.063-.063-.126-.125-.312-.344-.781-.437-1.281-.063-.187-.063-.406-.063-.625 0-1.656 1.313-3 3-3h3.031c.25 0 .438-.062.563-.156s.125-.188.125-.25"})}))},ge=function(e){return(0,ce.jsx)("svg",(0,le.A)((0,le.A)({xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 16 16"},e),{},{children:(0,ce.jsx)("path",{fillRule:"evenodd",d:"M10.218 3.216a.75.75 0 1 0-1.436-.431l-3 10a.75.75 0 0 0 1.436.43zM4.53 4.97a.75.75 0 0 1 0 1.06L2.56 8l1.97 1.97a.75.75 0 0 1-1.06 1.06l-2.5-2.5a.75.75 0 0 1 0-1.06l2.5-2.5a.75.75 0 0 1 1.06 0m6.94 6.06a.75.75 0 0 1 0-1.06L13.44 8l-1.97-1.97a.75.75 0 0 1 1.06-1.06l2.5 2.5a.75.75 0 0 1 0 1.06l-2.5 2.5a.75.75 0 0 1-1.06 0",clipRule:"evenodd"})}))},pe=function(e){return(0,ce.jsx)("svg",(0,le.A)((0,le.A)({xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 16 16"},e),{},{children:(0,ce.jsx)("path",{fillRule:"evenodd",d:"M11.615 4.888c.814-.375.885-.714.885-.888s-.071-.513-.885-.888C10.8 2.737 9.538 2.5 8 2.5s-2.799.237-3.615.612C3.57 3.487 3.5 3.826 3.5 4s.071.513.885.888C5.2 5.263 6.462 5.5 8 5.5s2.799-.237 3.615-.612m.885 1.235C11.4 6.708 9.792 7 8 7s-3.4-.292-4.5-.877V8c0 .174.071.513.885.888C5.2 9.263 6.462 9.5 8 9.5s2.799-.237 3.615-.612c.814-.375.885-.714.885-.888zm0 4C11.4 10.708 9.792 11 8 11s-3.4-.293-4.5-.877V12c0 .174.071.513.885.887.816.377 2.077.613 3.615.613s2.799-.236 3.615-.613c.814-.374.885-.713.885-.887zM14 4c0-2-2.686-3-6-3S2 2 2 4v8c0 2 2.686 3 6 3s6-1 6-3V4",clipRule:"evenodd"})}))};var me=n(54080),he=n(64969),fe=n(14881),_e=n(5623),Ae=n(53933);const ve=function(e){return(0,ce.jsx)("svg",(0,le.A)((0,le.A)({xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 16 16"},e),{},{children:(0,ce.jsx)("path",{fillRule:"evenodd",d:"m3.003 4.702 4.22-2.025a1.8 1.8 0 0 1 1.554 0l4.22 2.025a.89.89 0 0 1 .503.8V6a8.55 8.55 0 0 1-3.941 7.201l-.986.631a1.06 1.06 0 0 1-1.146 0l-.986-.63A8.55 8.55 0 0 1 2.5 6v-.498c0-.341.196-.652.503-.8m3.57-3.377L2.354 3.35A2.39 2.39 0 0 0 1 5.502V6a10.05 10.05 0 0 0 4.632 8.465l.986.63a2.56 2.56 0 0 0 2.764 0l.986-.63A10.05 10.05 0 0 0 15 6v-.498c0-.918-.526-1.755-1.354-2.152l-4.22-2.025a3.3 3.3 0 0 0-2.852 0M9.5 7a1.5 1.5 0 0 1-.75 1.3v1.95a.75.75 0 0 1-1.5 0V8.3A1.5 1.5 0 1 1 9.5 7",clipRule:"evenodd"})}))},Ne=function(e){return(0,ce.jsx)("svg",(0,le.A)((0,le.A)({xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 16 16"},e),{},{children:(0,ce.jsx)("path",{fillRule:"evenodd",d:"M4 3.5h1.25v2H2.5V5A1.5 1.5 0 0 1 4 3.5m2.75 2v-2H12A1.5 1.5 0 0 1 13.5 5v.5zM2.5 7h2.75v2H2.5zm0 3.5v.5A1.5 1.5 0 0 0 4 12.5h1.25v-2zm4.25 0v2H12a1.5 1.5 0 0 0 1.5-1.5v-.5zM13.5 9V7H6.75v2zM1 5a3 3 0 0 1 3-3h8a3 3 0 0 1 3 3v6a3 3 0 0 1-3 3H4a3 3 0 0 1-3-3z",clipRule:"evenodd"})}))},Te=function(e){return(0,ce.jsx)("svg",(0,le.A)((0,le.A)({xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 16 16"},e),{},{children:(0,ce.jsx)("path",{fillRule:"evenodd",d:"M8 13.5a5.5 5.5 0 1 0 0-11 5.5 5.5 0 0 0 0 11M8 15A7 7 0 1 0 8 1a7 7 0 0 0 0 14m1-9.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0m-.25 3a.75.75 0 0 0-1.5 0V11a.75.75 0 0 0 1.5 0z",clipRule:"evenodd"})}))},Ee=function(e){return(0,ce.jsx)("svg",(0,le.A)((0,le.A)({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16"},e),{},{children:(0,ce.jsx)("path",{fill:"currentColor",fillRule:"evenodd",d:"M9.357 7H6.643l1.08 6.267a.28.28 0 0 0 .554 0zM4.511 3.465l-.153-.691a.35.35 0 0 0-.684.007L2.522 8.537a1.14 1.14 0 0 0 .39 1.103l3.11 2.593zm5.466 8.768 3.111-2.593a1.14 1.14 0 0 0 .39-1.103l-1.152-5.756a.35.35 0 0 0-.684-.007l-.153.692zm-8.026-1.44 4.493 3.743a2 2 0 0 0 1.28.464h.552a2 2 0 0 0 1.28-.464l4.493-3.743a2.64 2.64 0 0 0 .9-2.55l-1.152-5.756a1.85 1.85 0 0 0-3.619-.039L9.5 5.5h-3l-.678-3.052a1.85 1.85 0 0 0-3.62.039l-1.15 5.756a2.64 2.64 0 0 0 .9 2.55",clipRule:"evenodd"})}))};var Oe=n(76091),Se=n(83189),be=n(29081),xe=n(31229),Ie=n(29746),we=n(23860),ye=n(19314),Ce=n(45033),Re=n(66026),Le=n(29121),je=n(12937),Ve=n(66134),Ge=n(10785),ke=n(80268),Be=n(28325),Pe=n(59028),Ue=n(79329),Me=(0,s.A)("elements-page"),De=function(e){function t(){return(0,Le.A)(this,t),(0,Ve.A)(this,t,arguments)}return(0,Ge.A)(t,e),(0,je.A)(t,[{key:"render",value:function(){var e=this.props,t=e.annotationHighlight,n=e.settingName,s=e.annotation,r=e.setSetting,o=e.getSetting,a=e.settingNS,l=e.label,c=e.oneLine,u=e.useSwitch,d=e.qa,g=o(n,a);return(0,ce.jsxs)("div",{className:Me("settings-item",{size:"s",name:n,"one-line":c}),title:l,children:[u?(0,ce.jsx)(ke.d,{checked:g,onUpdate:function(e){return r(n,a,e)},qa:d}):(0,ce.jsx)(Be.S,{content:l,checked:g,onUpdate:function(e){return r(n,a,e)},qa:d}),(0,ce.jsxs)("div",{className:Me("settings-annotation","elements-secondary-text"),children:[(0,ce.jsx)("span",{dangerouslySetInnerHTML:{__html:s}}),t&&(0,ce.jsxs)(i.Fragment,{children:[(0,ce.jsx)("br",{}),(0,ce.jsx)("span",{className:Me("settings-annotation-highlight"),dangerouslySetInnerHTML:{__html:t}})]})]})]})}}])}(i.Component);const Fe=(0,$.Ng)((function(e){return{getSetting:(0,Ue.th)(e)}}),{setSetting:Pe.ZC})(De);var He=n(18801),ze=n(87604),Ke=["name","items","heading","description","convertValue","onChange","onAfterChange","set","get"],Ye=["settingName","settingNS","getSetting","setSetting","onChange"],qe=(0,s.A)("elements-page"),Qe=function(e){var t=e.name,n=e.items,s=e.heading,r=e.description,o=e.convertValue,a=void 0===o?function(e){return e}:o,l=e.onChange,c=e.onAfterChange,u=e.set,d=e.get,g=(0,He.A)(e,Ke),p=i.useCallback((function(e){var t=a(e.target.value);if(l)return l(t);var n=u(t);return c&&c(),n}),[a,l,u,c]);return(0,ce.jsxs)("div",{className:qe("settings-item"),children:[s&&(0,ce.jsx)("div",{className:qe("settings-radio-heading"),children:s}),(0,ce.jsx)(ze.A,(0,le.A)((0,le.A)({},g),{},{size:"m",items:n,name:t,onChange:p,value:String(d())})),r&&(0,ce.jsx)("div",{className:qe("settings-description","elements-secondary-text"),children:r})]})};const We=(0,$.Ng)((function(e){return{getSetting:(0,Ue.th)(e)}}),{setSetting:Pe.ZC})((function(e){var t=e.settingName,n=e.settingNS,s=e.getSetting,r=e.setSetting,o=e.onChange,a=(0,He.A)(e,Ye),l=i.useCallback((function(e){o&&o(t,n,e)}),[o,n,t]),c=i.useCallback((function(e){return r(t,n,e)}),[r,n,t]),u=i.useCallback((function(){return s(t,n)}),[s,n,t]);return(0,ce.jsx)(Qe,(0,le.A)((0,le.A)({},a),{},{name:t,onChange:o?l:void 0,set:c,get:u}))}));var Je=n(9736),$e=(0,s.A)("elements-page");const Ze=(0,$.Ng)((function(e){return{getSetting:(0,Ue.th)(e)}}),{setSetting:Pe.ZC})((function(e){var t=e.getSetting,n=e.setSetting,s=e.settingName,r=e.settingNS,o=e.heading,a=e.description,l=e.placeholder,c=e.validator,u=t(s,r),d=(0,i.useState)(u),p=(0,Je.A)(d,2),m=p[0],h=p[1],f=null==c?void 0:c(m),_=(0,i.useCallback)((function(){f||n(s,r,m)}),[n,s,r,m]);return(0,ce.jsxs)("div",{className:$e("settings-item"),children:[o&&(0,ce.jsx)("div",{className:$e("settings-radio-heading"),children:o}),(0,ce.jsx)(g.k,{hasClear:!0,size:"m",placeholder:l,onUpdate:h,onBlur:_,error:f,value:m}),a&&(0,ce.jsx)("div",{className:$e("settings-description","elements-secondary-text"),children:a})]})}));var Xe=n(52797),et=n(79366),tt=n(58701),nt=n(33547),it=n(76426),st=n(58299),rt=n(53775),ot=n(28407),at=n(67270),lt=n(18123),ct=n(41487),ut=(0,s.A)("add-token-form"),dt=function(){var e=(0,$.wA)(),t=(0,i.useState)(!1),n=(0,Je.A)(t,2),s=n[0],r=n[1],o=(0,i.useState)(),a=(0,Je.A)(o,2),l=a[0],c=a[1],u=(0,i.useState)(""),d=(0,Je.A)(u,2),p=d[0],m=d[1],h=(0,$.d4)(ct.Dh);(0,i.useEffect)((function(){e((0,lt.cP)())}),[e]);var f=function(){var t=(0,ot.A)((0,rt.A)().mark((function t(){return(0,rt.A)().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!l||!p){t.next=10;break}return t.prev=1,r(!0),t.next=5,e((0,lt.f7)(l,p));case 5:return t.prev=5,r(!1),c(void 0),m(""),t.finish(5);case 10:case"end":return t.stop()}}),t,null,[[1,,5,10]])})));return function(){return t.apply(this,arguments)}}(),_=(0,i.useMemo)((function(){return h.reduce((function(e,t){if("none"===t.auth)return e;var n=t.id,i=t.name;return e.push({value:n,text:i}),e}),[])}),[h]);return(0,ce.jsxs)("div",{className:ut(),children:[(0,ce.jsx)(at.L,{items:_,value:l,onChange:c,hasClear:!0,placeholder:"VCS"}),(0,ce.jsx)(g.k,{placeholder:"token",value:p,onUpdate:m,hasClear:!0}),(0,ce.jsx)(T.$,{view:"action",onClick:f,loading:s,children:"Save"})]})},gt=n(79988),pt=(0,s.A)("vcs-list-item"),mt=function(e){var t=e.vcsId,n=e.name,s=e.onClick,r=i.useState(!1),o=(0,Je.A)(r,2),a=o[0],l=o[1],c=function(){var e=(0,ot.A)((0,rt.A)().mark((function e(){return(0,rt.A)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return l(!0),e.next=3,s(t);case 3:l(!1);case 4:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return(0,ce.jsxs)("div",{className:pt(),children:[(0,ce.jsx)("span",{children:n})," ",(0,ce.jsx)(st.A,{onClick:c,view:"flat",loading:a,children:(0,ce.jsx)(u.I,{data:gt.A,size:16})})]})},ht=(0,s.A)("vcs-list"),ft=function(e){var t=e.config,n=(0,$.wA)(),s=(0,i.useCallback)((function(e){return n((0,lt.eF)(e))}),[n]),r=(0,i.useMemo)((function(){return t.reduce((function(e,t){var n=t.id,i=t.name;return t.hasToken&&e.push((0,ce.jsx)(mt,{vcsId:n,name:i,onClick:s},n)),e}),[])}),[t,s]);return(0,ce.jsx)("div",{className:ht(),children:(0,ce.jsx)("div",{children:r})})},_t=n(30513),At=n(95942),vt=(0,s.A)("yt-settings-item");function Nt(e){var t=e.title,n=e.children,i=e.description,s=e.oneLine;return(0,ce.jsxs)("div",{className:vt({size:"s","one-line":s}),title:t,children:[n,(0,ce.jsx)("div",{className:vt("annotation","elements-secondary-text"),children:i})]})}var Tt=["settingKey","options"],Et=(0,s.A)("elements-page"),Ot=function(e){var t=e.getSetting(),n=(0,i.useState)("options"in e?e.options:[]),s=(0,Je.A)(n,2),r=s[0],o=s[1];return(0,i.useEffect)((function(){"getOptionsOnMount"in e&&(null==e||e.getOptionsOnMount().then((function(e){o(e)})))}),[]),(0,ce.jsx)("div",{className:Et("settings-item",{select:!0}),title:e.label,children:(0,ce.jsx)(at.L,{value:t,items:r,onChange:function(t){return e.setSetting(t)},placeholder:e.placeholder,width:"max"})})};function St(e){var t=e.settingKey,n=e.options,s=(0,He.A)(e,Tt),r=function(e){var t=(0,$.wA)();return{value:(0,$.d4)(At.u)[e],onUpdate:i.useCallback((function(n){t((0,Pe.rw)(e,n))}),[e])}}(t),o=r.value,a=r.onUpdate;return(0,ce.jsx)(Nt,(0,le.A)((0,le.A)({},s),{},{children:(0,ce.jsx)(_t.a,{options:n,value:o,onUpdate:a})}))}var bt=["settingKey"];function xt(e){var t=e.settingKey,n=(0,He.A)(e,bt),i=(0,$.wA)(),s=(0,$.d4)(At.u)[t];return(0,ce.jsx)(Nt,(0,le.A)((0,le.A)({},n),{},{children:(0,ce.jsx)(Be.S,{content:n.title,checked:Boolean(s),onUpdate:function(e){i((0,Pe.rw)(t,e))},qa:t})}))}var It=n(64735),wt=n(92611);const yt=JSON.parse('{"title_queries":"Queries","field_default-aco":"Default ACO","field_new-graph-progress":"Use new graph progress","context_new-graph-progress-description":"Enable experimental graph view for Progress tab of a query","field_query-assistant":"Query assistant","context_query-assistant-description":"Use query assistant to autocomplete","context_tab-accept-suggestion":"[Tab] - accept suggestion","context_esc-decline-suggestion":"[Esc] - decline suggestion","title_query-token":"Request tokens","title_existing-query-tokens":"Existing query tokens"}'),Ct=JSON.parse('{"title_queries":"Запросы","field_default-aco":"ACO по умолчанию","field_new-graph-progress":"Использовать новый граф прогресса","context_new-graph-progress-description":"Включить экспериментальный вид графа для вкладки Прогресс запроса","field_query-assistant":"Помощник по запросам","context_query-assistant-description":"Использовать помощника по запросам для автозаполнения","context_tab-accept-suggestion":"[Tab] - принять предложение","context_esc-decline-suggestion":"[Esc] - отклонить предложение","title_query-token":"Токены запроса","title_existing-query-tokens":"Существующие токены запросов"}'),Rt=(0,wt.Kc)("yt:settings-queries",{en:yt,ru:Ct});var Lt=n(61525),jt=n(51194),Vt=n(57018),Gt=function(){var e=(0,jt._)(),t=(0,$.d4)(Vt.B8);return(0,ce.jsx)(Ot,{getOptionsOnMount:function(){return e((0,Lt.N)()).then((function(e){return e.access_control_objects.reduce((function(e,t){return e.push({value:t,text:t}),e}),[])}))},setSetting:function(t){return t&&e((0,Lt.C)(t))},getSetting:function(){return t}})},kt=function(e){var t=e.cluster,n=e.hasQuerySuggestions;return Ht(Rt("title_queries"),void 0,X()([t&&Kt("defaultACO",Rt("field_default-aco"),void 0,(0,ce.jsx)(Gt,{})),Kt("global::queryTracker::useNewGraphView",Rt("field_new-graph-progress"),"top",(0,ce.jsx)(xt,{settingKey:"global::queryTracker::useNewGraphView",description:Rt("context_new-graph-progress-description"),oneLine:!0}))].concat((0,J.A)(n?[Kt("global::queryTracker::suggestions",Rt("field_query-assistant"),"top",(0,ce.jsx)(xt,{settingKey:"global::queryTracker::suggestions",description:(0,ce.jsxs)(m.s,{direction:"column",children:[(0,ce.jsx)("div",{children:Rt("context_query-assistant-description")}),(0,ce.jsx)(N.E,{color:"secondary",children:Rt("context_tab-accept-suggestion")}),(0,ce.jsx)(N.E,{color:"secondary",children:Rt("context_esc-decline-suggestion")})]}),oneLine:!0}))]:[]),[Kt("addQtTokenForm",Rt("title_query-token"),"top",(0,ce.jsx)(It.rJ,{})),Kt("existingQtTokenList","","top",(0,ce.jsx)(It.mT,{}))])))};const Bt=JSON.parse('{"Language":"Language"}'),Pt=(0,wt.Kc)("yt:settings-description",{en:Bt,ru:{Language:"Язык"}});var Ut=xe.mH.oauthTokenUrl,Mt=i.memo(qt);function Dt(e){return'<span class="unipika"><span class="escape">'.concat(e,"</span></span>")}function Ft(e,t){var n=(0,$.d4)(Re.Pn),i=(0,$.d4)(Xe.N3),s=(0,$.d4)(Xe.R9),r=(0,$.d4)(Xe.Y),o=(0,$.d4)(ct.Dh),a=(0,$.d4)(ct.V$),l=Boolean(ae.Ay.getInlineSuggestionsApi());return X()([Ht("General",ue,[Kt("startPage","Start page","top",(0,ce.jsx)(Mt,{})),Kt("global::newDashboardPage","New dashboard page","top",(0,ce.jsx)(xt,{settingKey:"global::newDashboardPage",description:"Enable new dashboard page",oneLine:!0})),Kt(ye.Ou.GLOBAL.AUTO_REFRESH,"Use auto refresh","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.GLOBAL.AUTO_REFRESH,settingNS:ye.dK.GLOBAL,annotation:"Automatically update pages with highly dynamic content",oneLine:!0})),Kt(ye.Ou.MENU.RECENT_CLUSTER_FIRST,"Use recent clusters","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.MENU.RECENT_CLUSTER_FIRST,settingNS:ye.dK.MENU,annotation:"Recently visited clusters appear at the top of cluster menu.",oneLine:!0})),Kt(ye.Ou.MENU.RECENT_PAGE_FIRST,"Use recent pages","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.MENU.RECENT_PAGE_FIRST,settingNS:ye.dK.MENU,annotation:"Recently visited pages appear at the top of pages menu.",oneLine:!0}))]),Ht("Appearance",de,[Kt(ye.Ou.GLOBAL.THEME,"Theme","top",(0,ce.jsx)(We,{settingName:ye.Ou.GLOBAL.THEME,settingNS:ye.dK.GLOBAL,items:[{value:"light",text:"Light"},{value:"dark",text:"Dark"},{value:"system",text:"System"}]})),Kt(ye.Ou.A11Y.USE_SAFE_COLORS,"Contrast","top",(0,ce.jsx)(We,{settingName:ye.Ou.A11Y.USE_SAFE_COLORS,settingNS:ye.dK.A11Y,convertValue:function(e){return"true"===e},items:[{value:"false",text:"Normal"},{value:"true",text:"High"}]})),{id:"global::maxContentWidth",title:"Content width",align:"top",content:(0,ce.jsx)(St,{settingKey:"global::maxContentWidth",options:[{value:"standard",content:"Standard"},{value:"wide",content:"Wide"},{value:"maximum",content:"Maximum"}]})}]),Ht("Development",ge,X()([t&&Kt(ye.Ou.DEVELOPMENT.REGULAR_USER_UI,"Show regular user's UI","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.DEVELOPMENT.REGULAR_USER_UI,settingNS:ye.dK.DEVELOPMENT,label:"Show regular user's UI",annotation:"There is some difference in UI for development-team and regular users, enabling of the option allows to see exactly the same what see a regular user."})),t&&Kt("global::lang",Pt("Language"),"top",(0,ce.jsx)(St,{settingKey:"global::lang",options:[{value:"en",content:"English"},{value:"ru",content:"Русский"}]})),Kt(ye.Ou.QUERY_TRACKER.STAGE,"Query Tracker Stage","top",(0,ce.jsx)(Ze,{placeholder:"Enter stage...",description:"Default Query Tracker stage is 'production'. But you can reassign it with this setting.",settingName:ye.Ou.QUERY_TRACKER.STAGE,settingNS:ye.dK.QUERY_TRACKER})),Kt(ye.Ou.QUERY_TRACKER.YQL_AGENT_STAGE,"YQL agent stage","top",(0,ce.jsx)(Ze,{placeholder:"Enter YQL agent stage...",settingName:ye.Ou.QUERY_TRACKER.YQL_AGENT_STAGE,settingNS:ye.dK.QUERY_TRACKER}))])),Ht("Data",pe,[Kt(ye.Ou.YSON.FORMAT,"Data format","top",(0,ce.jsx)(We,{settingName:ye.Ou.YSON.FORMAT,settingNS:ye.dK.YSON,items:[{value:"yson",text:"YSON"},{value:"json",text:"JSON"},{value:"raw-json",text:"Raw JSON"}]})),Kt(ye.Ou.YSON.SHOW_DECODED,"Decode data as UTF8","top",(0,ce.jsx)(Fe,{oneLine:!0,settingName:ye.Ou.YSON.SHOW_DECODED,settingNS:ye.dK.YSON,annotation:"Attempt to decode UTF-8 strings. Show Unicode symbols upon success and mark data as binary otherwise.",annotationHighlight:"Please note that YSON does not natively support Unicode symbols &mdash; therefore you would not be able to copy-paste presented YSON as is."})),Kt(ye.Ou.YSON.BINARY_AS_HEX,"Binary as HEX","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.YSON.BINARY_AS_HEX,settingNS:ye.dK.YSON,annotation:"Display binary strings as HEX sequences. Strings that were not decoded as UTF8 are therefore considered binary and displayed as HEX sequences.",oneLine:!0})),Kt(ye.Ou.YSON.ESCAPE_WHITESPACES,"Escape and highlight","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.YSON.ESCAPE_WHITESPACES,settingNS:ye.dK.YSON,annotation:"Symbols ".concat(Dt("\\n")," and ").concat(Dt("\\t")," will be rendered as escape sequences, whitespaces will be ")+"highlighted as neccessary. Does not affect Raw JSON format.",annotationHighlight:"Please note that JSON does not support unescaped control characters &mdash; therefore you would not be able to copy-paste presented JSON as is.",oneLine:!0})),Kt(ye.Ou.YSON.COMPACT,"Compact view","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.YSON.COMPACT,settingNS:ye.dK.YSON,annotation:"Single element lists are rendered inline, so are maps with one property. Does not affect Raw JSON format.",oneLine:!0}))]),Ht("System",me.A,[Kt(ye.Ou.SYSTEM.MASTERS_HOST_TYPE,"Host type of Masters/Schedulers/Controller","top",(0,ce.jsx)(We,{description:"Select the default view of host to display on in the Masters/Schedulers and Controller agents section.",settingName:ye.Ou.SYSTEM.MASTERS_HOST_TYPE,settingNS:ye.dK.SYSTEM,items:he.t}))]),Ht("Operation",fe.A,[Kt(ye.Ou.OPERATIONS.STATISTICS_AGGREGATION_TYPE,"Statistic's type","top",(0,ce.jsx)(We,{description:"Select the default type of job aggregation.",settingName:ye.Ou.OPERATIONS.STATISTICS_AGGREGATION_TYPE,settingNS:ye.dK.OPERATIONS,items:we.ne}))]),Ht("Navigation",Ae.A,X()([n&&Kt(ye.Ou.LOCAL.NAVIGATION_DEFAULT_PATH,"Default path","top",(0,ce.jsx)(Ze,{placeholder:"Enter default navigation path...",description:"Cluster specific path that will be opened by default in the the Navigation page.",validator:Qt,settingName:ye.Ou.LOCAL.NAVIGATION_DEFAULT_PATH,settingNS:n})),Kt(ye.Ou.NAVIGATION.DEFAULT_CHYT_ALIAS,"Default chyt alias","top",(0,ce.jsx)(Ze,{placeholder:"Enter default chyt alias...",description:"User alias for the YQL Kit default query string in ClickHouse mode.",validator:Wt,settingName:ye.Ou.NAVIGATION.DEFAULT_CHYT_ALIAS,settingNS:ye.dK.NAVIGATION})),Kt(ye.Ou.NAVIGATION.USE_SMART_SORT,"Use smart sort","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.NAVIGATION.USE_SMART_SORT,settingNS:ye.dK.NAVIGATION,annotation:"Nodes with names that represent dates will be sorted from newest date to oldest, while other nodes will be sorted alphabetically.",oneLine:!0})),Kt(ye.Ou.NAVIGATION.GROUP_NODES,"Group nodes by type","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.NAVIGATION.GROUP_NODES,settingNS:ye.dK.NAVIGATION,annotation:"Nodes will be grouped by type and each type will be sorted independently, folders first, then tables, then files.",oneLine:!0})),Kt(ye.Ou.NAVIGATION.USE_SMART_FILTER,"Use smart filter","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.NAVIGATION.USE_SMART_FILTER,settingNS:ye.dK.NAVIGATION,annotation:'Use logical operators in filter like "and" and "or"',oneLine:!0})),Kt(ye.Ou.NAVIGATION.ENABLE_PATH_AUTO_CORRECTION,"Path autocorrection","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.NAVIGATION.ENABLE_PATH_AUTO_CORRECTION,settingNS:ye.dK.NAVIGATION,annotation:"Autocorrect erroneous path if possible. "+(0,be.fs)("For details see "+'<a class="link link_theme_normal" href="'.concat(ae.Ay.docsUrls["faq:enablepathautocorrection"],'" target="_blank">FAQ</a>')+"."),oneLine:!0}))])),zt("Components",_e.A,[{title:"General",items:[Kt(ye.Ou.COMPONENTS.ENABLE_SIDE_BAR,"Enable side bar","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.COMPONENTS.ENABLE_SIDE_BAR,settingNS:ye.dK.COMPONENTS,annotation:"Display node data in the side bar when clicked.",oneLine:!0}))]},{title:"Memory popup",items:[Kt("global::components::memoryPopupShowAll","Show empty categories","top",(0,ce.jsx)(xt,{settingKey:"global::components::memoryPopupShowAll",description:"Display all memory categories even with 0B",oneLine:!0}))]}]),Ht("Table",Ne,X()([Kt(ye.Ou.DEVELOPMENT.YQL_TYPES,"YQL V3 types","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.DEVELOPMENT.YQL_TYPES,settingNS:ye.dK.DEVELOPMENT,qa:"settings_yql-v3-types",oneLine:!0})),Kt(ye.Ou.NAVIGATION.ROWS_PER_TABLE_PAGE,"Rows per page","top",(0,ce.jsx)(We,{description:"Select the default number of rows to display on one table page. The number can be changed for the specific table using table settings button.",settingName:ye.Ou.NAVIGATION.ROWS_PER_TABLE_PAGE,settingNS:ye.dK.NAVIGATION,items:[{value:String(10),text:"10"},{value:String(50),text:"50"},{value:String(100),text:"100"},{value:String(200),text:"200"}],convertValue:Number})),Kt(ye.Ou.NAVIGATION.MAXIMUM_TABLE_STRING_SIZE,"Cell size limit","top",(0,ce.jsx)(We,{description:"Select the default cell size limit for tables. The cell size limit for the specific table can be changed using table settings button.",settingName:ye.Ou.NAVIGATION.MAXIMUM_TABLE_STRING_SIZE,settingNS:ye.dK.NAVIGATION,items:tt.B,convertValue:Number})),Kt(ye.Ou.NAVIGATION.DEFAULT_TABLE_COLUMN_LIMIT,"Default column limit","top",(0,ce.jsx)(We,{description:"Select the default column limit for tables. In other words, how many columns will be shown when no column has even been hidden using ColumnSelector for the particular table or (if table similarity is enabled) for the similar table.",settingName:ye.Ou.NAVIGATION.DEFAULT_TABLE_COLUMN_LIMIT,settingNS:ye.dK.NAVIGATION,items:tt.Cj,convertValue:Number})),Kt(ye.Ou.NAVIGATION.ENABLE_TABLE_SIMILARITY,"Guess visible columns","top",(0,ce.jsx)(Fe,{settingName:ye.Ou.NAVIGATION.ENABLE_TABLE_SIMILARITY,settingNS:ye.dK.NAVIGATION,annotation:"Use table similarity for guessing visible columns. Show same visible columns in table A as in table B if these tables are similar and those columns have been previously set as visible for table B.",oneLine:!0})),Kt(ye.Ou.NAVIGATION.TABLE_DISPLAY_RAW_STRINGS,"Allow raw string-values","top",(0,ce.jsx)(Fe,{annotation:"Cells with string values will be displayed without escaping.",settingName:ye.Ou.NAVIGATION.TABLE_DISPLAY_RAW_STRINGS,settingNS:ye.dK.NAVIGATION,oneLine:!0}))])),Ut&&Ht("Auth",ve,[Kt("oauthToken","YT OAuth token",void 0,(0,ce.jsx)(it.A,{url:Ut,target:"_blank",children:(0,ce.jsx)(st.A,{size:"s",children:"Show my token"})}))]),a&&Ht("VCS",Ee,X()([Kt("addTokenForm","Add or replace token",void 0,(0,ce.jsx)(dt,{})),Boolean(o.some((function(e){return e.hasToken})))&&Kt("existingTokenList","Existing tokens",void 0,(0,ce.jsx)(ft,{config:o}))])),zt("Editor",Oe.A,[{title:"Visual settings",items:[Kt("global::editor::vimMode","Vim mode","top",(0,ce.jsx)(xt,{settingKey:"global::editor::vimMode",description:"Use monaco vim mode",oneLine:!0}))]}]),kt({cluster:e,hasQuerySuggestions:l}),Ht("About",Te,X()([Boolean(e)&&Kt("httpProxyVersion","HTTP proxy version",void 0,i),Boolean(e)&&Kt("schedulerVersion","Scheduler version",void 0,s),Boolean(e)&&Kt("masterVersion","Master version",void 0,r),Kt("interfaceVersion","Interface version",void 0,nt.YT.parameters.interface.version)]))])}function Ht(e,t,n){return zt(e,t,[{title:e,items:n}])}function zt(e,t,n){return{title:e,icon:t||ue,sections:n}}function Kt(e,t,n,i){return{id:e,title:t,align:n,content:i}}function Yt(e){return re()(e,(function(e,t){return e[t.title]=t,e}),{})}function qt(){var e=(0,$.d4)(Ce.WK).all,t=i.useMemo((function(){var t=te()(e,(function(e){return Boolean(e.header)}));return o()(t,(function(e){return{value:e.id,text:e.name}}))}),[e]);return(0,ce.jsx)(We,{settingName:ye.Ou.MENU.STARTING_PAGE,settingNS:ye.dK.MENU,items:t})}function Qt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"/";if(!e)return null;try{return void Ie.A.YPath.create(e,"absolute")}catch(e){return(null==e?void 0:e.message)||"invalid path"}}function Wt(e){if(!e.startsWith("*")&&e.length>0)return"The alias should be started with a character '*'"}var Jt=(0,s.A)("settings-panel");function $t(e){return{data:e}}function Zt(){var e=function(){var e=(0,$.d4)(et.Xn)||!0,t=(0,Se.x)(),n=(0,$.d4)(Xe.ID),s=Ft(t,e),r=ae.Ay.getExternalSettings({cluster:t,isAdmin:e,login:n});return i.useMemo((function(){var e=Yt(r);return(0,oe.jM)(s,(function(t){ie()(t,(function(t){var n=e[t.title];if(n){delete e[t.title];var i=Yt(n.sections);ie()(t.sections,(function(e){var t=i[e.title];if(t){delete i[e.title];var n=new Map(t.items.map((function(e){return[e.id,e]}))),s=e.items.filter((function(e){return!n.has(e.id)}));e.items=[].concat((0,J.A)(s),(0,J.A)(t.items))}})),ie()(i,(function(e){t.sections.push(e)}))}})),ie()(e,(function(e){t.splice(t.length-1,0,e)}))}))}),[s,r])}();return(0,ce.jsx)("div",{className:Jt(),children:(0,ce.jsx)(Y,{children:o()(e,(function(e,t){return l()(e.sections,(function(e){return e.items.length>0}))&&(0,ce.jsx)(Y.Page,{title:e.title,icon:$t(e.icon),children:o()(e.sections,(function(e,t){return(0,ce.jsx)(Y.Section,{title:e.title,children:o()(e.items,(function(e,t){return(0,ce.jsx)(Y.Item,{title:e.title,align:e.align,children:e.content},t)}))},t)}))},t)}))})})}const Xt=i.memo(Zt)},24686:(e,t,n)=>{n.d(t,{CG:()=>l,M7:()=>a,gU:()=>r,xK:()=>o});var i=n(18472),s=n(29970),r=function(e){return e.queryTracker.queryFilesModal.fileEditor},o=function(e){return e.queryTracker.queryFilesModal.deletedFiles},a=(0,i.Mz)([r,s._M,o],(function(e,t,n){var i="file"===e.fileType?t:n;return{fileEditor:e,file:i.find((function(t){return t.id===e.fileId}))}})),l=(0,i.Mz)([s._M,o,function(e){return e.queryTracker.queryFilesModal.addForm}],(function(e,t,n){return{files:e,deletedFiles:t,addFormOpen:n.isOpen,addFormType:n.type,showTabs:e.length>0||t.length>0||n.isOpen}}))},25003:(e,t,n)=>{n.d(t,{Ko:()=>A,TG:()=>v,cM:()=>_,wk:()=>T,yP:()=>N});var i=n(68175),s=n(40319),r=n(41655),o=n.n(r),a=n(26264),l=n(53246),c=n(59028),u=n(45033),d=n(62911),g=n(19314),p=n(79329),m=n(21594),h=n(52797);function f(e){return{cluster:g.dK.LAST_VISITED_CLUSTER,page:g.dK.LAST_VISITED_PAGE}[e]}function _(e){var t=e+"s";return function(n,i){var s=i(),r=(0,u.zy)(s),l=(0,u.WK)(s),c=i().settings.data;n({type:a.qG,data:{collectionName:t,items:"pages"===t?l.all:r.all,getLastVisitedSetting:function(t){return function(e,t){var n=f(e);return(0,m.Yn)(t,n)}(e,t.id)},settings:c,currentTime:o()().unix()}})}}function A(e){return{type:a.eV,data:e}}function v(e,t){return function(n){var i=f(e),s=o()().unix();n((0,c.ZC)(t,i,s)),n(_(e))}}function N(e){return function(t,n){var i=n(),s=(0,h.dB)(i),r=(0,h.ID)(i),o=(0,u.ex)(i);t(v("page",e)),t((0,l.ar)({page:o[e]})),t((0,l.Dw)()),window.setTimeout((function(){(0,d.m)().countHit({page:e,cluster:s,login:r})}),200)}}function T(e,t){return function(n,r){var o=r(),a=(0,p.sX)(o),l=(0,p.R9)(o),u=(0,s.A)((0,s.A)({},l),{},(0,i.A)({},e,t));n((0,c.ZC)(g.Ou.LOCAL.LAST_VISITED_TAB,a,u))}}},31816:(e,t,n)=>{n.d(t,{d:()=>L});var i="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==n.g?n.g:"undefined"!=typeof self?self:{},s=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)},r="object"==typeof i&&i&&i.Object===Object&&i,o="object"==typeof self&&self&&self.Object===Object&&self,a=r||o||Function("return this")(),l=a,c=/\s/,u=/^\s+/,d=a.Symbol,g=d,p=Object.prototype,m=p.hasOwnProperty,h=p.toString,f=g?g.toStringTag:void 0,_=Object.prototype.toString,A=function(e){var t=m.call(e,f),n=e[f];try{e[f]=void 0;var i=!0}catch(e){}var s=h.call(e);return i&&(t?e[f]=n:delete e[f]),s},v=d?d.toStringTag:void 0,N=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":v&&v in Object(e)?A(e):function(e){return _.call(e)}(e)},T=function(e){return e?e.slice(0,function(e){for(var t=e.length;t--&&c.test(e.charAt(t)););return t}(e)+1).replace(u,""):e},E=s,O=/^[-+]0x[0-9a-f]+$/i,S=/^0b[01]+$/i,b=/^0o[0-7]+$/i,x=parseInt,I=s,w=function(){return l.Date.now()},y=function(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return null!=e&&"object"==typeof e}(e)&&"[object Symbol]"==N(e)}(e))return NaN;if(E(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=E(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=T(e);var n=S.test(e);return n||b.test(e)?x(e.slice(2),n?2:8):O.test(e)?NaN:+e},C=Math.max,R=Math.min,L=function(e,t,n){var i,s,r,o,a,l,c=0,u=!1,d=!1,g=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function p(t){var n=i,r=s;return i=s=void 0,c=t,o=e.apply(r,n)}function m(e){var n=e-l;return void 0===l||n>=t||n<0||d&&e-c>=r}function h(){var e=w();if(m(e))return f(e);a=setTimeout(h,function(e){var n=t-(e-l);return d?R(n,r-(e-c)):n}(e))}function f(e){return a=void 0,g&&i?p(e):(i=s=void 0,o)}function _(){var e=w(),n=m(e);if(i=arguments,s=this,l=e,n){if(void 0===a)return function(e){return c=e,a=setTimeout(h,t),u?p(e):o}(l);if(d)return clearTimeout(a),a=setTimeout(h,t),p(l)}return void 0===a&&(a=setTimeout(h,t)),o}return t=y(t)||0,I(n)&&(u=!!n.leading,r=(d="maxWait"in n)?C(y(n.maxWait)||0,t):r,g="trailing"in n?!!n.trailing:g),_.cancel=function(){void 0!==a&&clearTimeout(a),c=0,i=l=s=a=void 0},_.flush=function(){return void 0===a?o:f(w())},_}},34072:(e,t,n)=>{function i(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var s=0;for(i=Object.getOwnPropertySymbols(e);s<i.length;s++)t.indexOf(i[s])<0&&Object.prototype.propertyIsEnumerable.call(e,i[s])&&(n[i[s]]=e[i[s]])}return n}n.d(t,{_:()=>i}),"function"==typeof SuppressedError&&SuppressedError},58860:(e,t,n)=>{n.d(t,{W:()=>f,b:()=>v});var i=n(74360),s=n(59117),r=n.n(s),o=n(84092),a=n.n(o),l=n(10720),c=n(13542),u=n(53332),d=n(26264),g=n(33547),p=n(52797),m=n(31229),h=n(3659);function f(e){var t=g.YT.clusters,n=(0,u.Jc)(t,e);a().setup.setGlobalOption("suppressAccessTracking",!0),a().setup.setGlobalOption("useEncodedParameters",!0),a().setup.setGlobalOption("proxy",(0,p.v9)(n)),!(0,m.FG)().ytApiUseCORS&&(n.secure="https:"===window.location.protocol),a().setup.setGlobalOption("useHeavyProxy",!1),a().setup.setGlobalOption("xsrf",!0),a().setup.setGlobalOption("xsrfCookieName",(0,u.fc)(n.id)),"boolean"==typeof n.secure?a().setup.setGlobalOption("secure",n.secure):a().setup.setGlobalOption("secure",!0),a().setup.setGlobalOption("authentication",{type:n.authentication||"none"}),a().subscribe("error",_)}function _(e){var t,n,i=e&&e.code;if(i===a().codes.USER_IS_BANNED)(0,c.ai)().dispatch({type:d.q8});else if(i===a().codes.USER_EXCEEDED_RPS)(0,c.ai)().dispatch({type:d.W6});else if(i==a().codes.XSRF_TOKEN_EXPIRED){var s="Your CSRF-token '".concat((n=(t=g.YT.cluster)&&(0,u.fc)(t))&&r().get(n),"' has expired. Please reaload the page");console.log(s),(new l.I).add({name:"xsrf-expired",theme:"info",autoHiding:!1,title:"CSRF-toke expired",content:s})}}var A=function(e){try{return h.A.decode(e)}catch(t){return e}},v={stringify:function(e){return JSON.stringify(e)},parse:function(e){return JSON.parse(e,(function(e,t){return"object"!==(0,i.A)(t)||null===t||Array.isArray(t)?t:Object.keys(t).reduce((function(e,n){return e[A(n)]="string"==typeof t[n]?A(t[n]):t[n],e}),{})}))}}},61525:(e,t,n)=>{n.d(t,{C:()=>g,N:()=>d});var i=n(53775),s=n(28407),r=n(10720),o=n(27859),a=n(29970),l=n(48971),c=n(88169),u=n(59028),d=function(){return function(e,t){var n=t(),i=(0,a.C3)(n).stage;return e({type:c.O.REQUEST}),o.$S.getQueryTrackerInfo(o.Vu.getQueryTrackerInfo,{setup:{transformError:function(e){var t,n,i=e.parsedData,s=e.rawError;if(404===(null==s||null===(t=s.response)||void 0===t?void 0:t.status))throw{data:i,status:null==s||null===(n=s.response)||void 0===n?void 0:n.status};throw i}},parameters:{stage:i}}).then((function(t){return e({type:c.O.SUCCESS,data:{data:t}}),t})).catch((function(t){404!==(null==t?void 0:t.status)&&(new r.I).add({name:"aco",theme:"danger",title:"Failed to load ACO",content:null==t?void 0:t.message,actions:[{label:" Details",onClick:function(){return(0,l.eW)(t)}}]}),e({type:c.O.FAILURE})}))}};function g(e){return function(){var t=(0,s.A)((0,i.A)().mark((function t(n,s){var r,o;return(0,i.A)().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=s(),o=(0,a.cm)(r),t.next=4,n((0,u.rw)("qt-stage::".concat(o,"::queryTracker::defaultACO"),e));case 4:case"end":return t.stop()}}),t)})));return function(e,n){return t.apply(this,arguments)}}()}},62167:(e,t,n)=>{n.d(t,{t:()=>m});var i=n(64922),s=n(77810),r=n(21086);const o=s.createContext({activeTabId:void 0});o.displayName="TabsContext";var a=n(46747);const l=(0,r.om)("tabs");function c({id:e,className:t,title:n,meta:r,hint:c,icon:u,counter:d,label:g,active:p,disabled:m,hasOverflow:h,extraProps:f,onClick:_,qa:A}){const{activeTabId:v}=s.useContext(o),N="boolean"==typeof p?p:v===e,T=s.useMemo((()=>void 0!==c?c:"string"==typeof n?n:void 0),[c,n]);return(0,i.jsxs)("div",Object.assign({},f,{role:"tab","aria-selected":N,"aria-disabled":!0===m,tabIndex:m?-1:0,className:l("item",{active:N,disabled:m,overflow:Boolean(h)},t),title:T,onClick:()=>{_(e)},onKeyDown:t=>{" "===t.key&&_(e)},"data-qa":A,children:[(0,i.jsxs)("div",{className:l("item-content"),children:[u&&(0,i.jsx)("div",{className:l("item-icon"),children:u}),(0,i.jsx)("div",{className:l("item-title"),children:n||e}),void 0!==d&&(0,i.jsx)("div",{className:l("item-counter"),children:d}),g&&(0,i.jsx)(a.J,{className:l("item-label"),theme:g.theme,children:g.content})]}),r&&(0,i.jsx)("div",{className:l("item-meta"),children:r})]}))}c.displayName="Tabs.Item";const u=(0,r.om)("tabs");var d;!function(e){e.Horizontal="horizontal",e.Vertical="vertical"}(d||(d={}));const g=[],p=s.forwardRef((({direction:e=d.Horizontal,size:t="m",activeTab:n,allowNotSelected:r=!1,items:a=g,children:l,className:p,onSelectTab:m,wrapTo:h,qa:f},_)=>{const A=((e,t,n)=>{var i;return e||(t||0===(null==n?void 0:n.length)||null===(i=null==n?void 0:n[0])||void 0===i?void 0:i.id)})(n,r,a),v=s.useMemo((()=>({activeTabId:A})),[A]),N=s.useMemo((()=>{const e=e=>{m&&m(e)};return a.map(((t,n)=>{const s=(0,i.jsx)(c,Object.assign({},t,{onClick:e}),t.id);return h?h(t,s,n):s}))}),[a,m,h]);return(0,i.jsx)("div",{role:"tablist",className:u({direction:e,size:t},p),"data-qa":f,ref:_,children:(0,i.jsx)(o.Provider,{value:v,children:l||N})})}));p.displayName="Tabs";const m=Object.assign(p,{Item:c})},64735:(e,t,n)=>{n.d(t,{_3:()=>u,mT:()=>c,rJ:()=>l});var i=n(53775),s=n(28407),r=n(77810),o=n(33882);function a(){return Promise.all([n.e(7954),n.e(4108),n.e(6652),n.e(2701),n.e(3996),n.e(2113),n.e(2431)]).then(n.bind(n,72136))}var l=(0,o.A)(r.lazy((0,s.A)((0,i.A)().mark((function e(){return(0,i.A)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a();case 2:return e.t0=e.sent.AddQueryTokenFormButton,e.abrupt("return",{default:e.t0});case 4:case"end":return e.stop()}}),e)}))))),c=(0,o.A)(r.lazy((0,s.A)((0,i.A)().mark((function e(){return(0,i.A)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a();case 2:return e.t0=e.sent.QueryTokenTable,e.abrupt("return",{default:e.t0});case 4:case"end":return e.stop()}}),e)}))))),u=(0,o.A)(r.lazy((0,s.A)((0,i.A)().mark((function e(){return(0,i.A)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a();case 2:return e.t0=e.sent.QueryTokenButton,e.abrupt("return",{default:e.t0});case 4:case"end":return e.stop()}}),e)})))))},64969:(e,t,n)=>{n.d(t,{T:()=>i,t:()=>s});var i={host:"host",physicalHost:"physicalHost"},s=[{value:i.host,text:"Container"},{value:i.physicalHost,text:"Host"}]},76091:(e,t,n)=>{n.d(t,{A:()=>r});var i=n(40319),s=n(64922);const r=function(e){return(0,s.jsx)("svg",(0,i.A)((0,i.A)({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16"},e),{},{children:(0,s.jsx)("path",{fill:"currentColor",fillRule:"evenodd",d:"M6.169 6.331a3 3 0 0 0-.833 1.6l-.338 1.912a1 1 0 0 0 1.159 1.159l1.912-.338a3 3 0 0 0 1.6-.833l3.07-3.07 2-2A.9.9 0 0 0 15 4.13 3.13 3.13 0 0 0 11.87 1a.9.9 0 0 0-.632.262l-2 2zm3.936-1.814L7.229 7.392a1.5 1.5 0 0 0-.416.8L6.6 9.4l1.208-.213.057-.01a1.5 1.5 0 0 0 .743-.406l2.875-2.876a1.63 1.63 0 0 0-1.378-1.378m2.558.199a3.14 3.14 0 0 0-1.379-1.38l.82-.82a1.63 1.63 0 0 1 1.38 1.38zM8 2.25a.75.75 0 0 0-.75-.75H4.5a3 3 0 0 0-3 3v7a3 3 0 0 0 3 3h7a3 3 0 0 0 3-3V8.75a.75.75 0 0 0-1.5 0v2.75a1.5 1.5 0 0 1-1.5 1.5h-7A1.5 1.5 0 0 1 3 11.5v-7A1.5 1.5 0 0 1 4.5 3h2.75A.75.75 0 0 0 8 2.25",clipRule:"evenodd"})}))}},80268:(e,t,n)=>{n.d(t,{d:()=>l});var i=n(64922),s=n(77810),r=n(21480),o=n(83541);const a=(0,n(21086).om)("switch"),l=s.forwardRef((function(e,t){const{size:n="m",disabled:s=!1,content:l,children:c,title:u,style:d,className:g,qa:p}=e,{checked:m,inputProps:h}=(0,r.v)(Object.assign(Object.assign({},e),{controlProps:Object.assign(Object.assign({},e.controlProps),{role:"switch"})})),f=l||c,_=(0,i.jsxs)("span",{className:a("indicator"),children:[(0,i.jsx)("input",Object.assign({},h,{className:a("control")})),(0,i.jsx)("span",{className:a("outline")}),(0,i.jsx)("span",{className:a("slider")})]});return(0,i.jsx)(o.m,{ref:t,title:u,style:d,size:n,disabled:s,className:a({size:n,disabled:s,checked:m},g),labelClassName:a("text"),qa:p,control:_,children:f})}))},86349:(e,t,n)=>{n.d(t,{Aq:()=>k,jj:()=>j,ok:()=>L,tH:()=>B});var i=n(53775),s=n(28407),r=n(9736),o=n(41169),a=n(84092),l=n.n(a),c=n(59117),u=n.n(c),d=n(29746),g=n(77575),p=n(26264),m=n(52797),h=n(53332),f=n(36581),_=n(79329),A=n(12680),v=n(10720),N=n(27859),T=n(11896),E=n(48971),O=n(33547),S=n(62250),b=n(58860),x=n(19314),I=n(53246),w=n(59028),y=n(25003);function C(e,t,n){(0,A.N1)({level:"warn",type:n,message:"".concat(e," cannot be loaded, some ui features might be not available"),block:e},t)}var R=new v.I;function L(e,t){return e.error&&e.error.code!==l().codes.NODE_DOES_NOT_EXIST&&(C("//sys/@ui_config",e.error),R.add({name:"get-ui_config",theme:"danger",autoHiding:!1,title:"Failed to load //sys/@ui_config",content:"Some UI features might be not available. Try to reload the page. If the problem persists please report it via Bug Reporter."})),t.error&&t.error.code!==l().codes.NODE_DOES_NOT_EXIST&&C("//sys/@ui_config_dev_overrides",t.error),[e.output||{},t.output||{}]}function j(e,t){return(0,E.fI)(e.fetch(N.Vu.clusterParams,o.A.request({url:"/api/cluster-params/"+t,method:"GET"})),{skipSuccessToast:!0,toasterName:"cluster_initialization_failure",errorTitle:"Cluster initialization failure",errorContent:"An error occured"})}function V(e){return function(t,n){(0,b.W)(e),t({type:p.Vk.REQUEST});var i=(0,m.ID)(n()),s=new N.CT(e,T.c.CLUSTER_PARAMS);return j(s,e).then((function(n){var o=n.data,a=o.mediumList,l=o.schedulerVersion,c=o.masterVersion,u=o.uiConfig,m=o.uiDevConfig,h=(0,E.$7)([a],"Cluster initialization failure");if(h)throw h;var f=L(u,m),_=(0,r.A)(f,2),A=_[0],v=_[1];return t({type:p.Vk.SUCCESS,data:{cluster:e,mediumList:d.A.getValue(a.output),isDeveloper:!1,clusterUiConfig:A,schedulerVersion:l.output,masterVersion:c.output}}),s.fetch(N.Vu.clusterParamsIsDeveloper,(0,g.h)(i,void 0,N.Vu.clusterParamsIsDeveloper)).then((function(e){if(e){var n=e?Object.assign({},A,v):A;t({type:S.wV,data:{isDeveloper:e,clusterUiConfig:n}})}})).catch((function(e){console.error("Failed to check if current user is admin",e)}))})).catch((function(e){t({type:p.Vk.FAILURE,data:e})}))}}var G=0;function k(e){return function(t,n){var r=function(e){var n;e instanceof Error&&console.error(e),t({type:p.pw.FAILURE,data:{error:(null==e||null===(n=e.response)||void 0===n?void 0:n.data)||e}})};return t({type:p.pw.REQUEST}),new N.CT(e,T.c.CLUSTER_PARAMS).fetch(N.Vu.ui_clusterInfo,o.A.request({url:"/api/cluster-info/"+e,method:"GET"})).then((function(o){var a,l=o.data,c=l.token,d=l.tokenError,g=l.version,m=l.versionError;if(G++&&t({type:f.A4,data:{shouldUsePreserveState:(0,_.qP)(n())}}),!g||m)t({type:p.pw.FAILURE,data:{errorType:p.NZ.CONNECTION,error:m}});else{if(t({type:p.pw.SUCCESS,data:{version:g}}),O.YT.parameters.version=g,O.YT.cluster=e,null!=c&&c.csrf_token&&!d){var A=c.login,v=c.csrf_token;return O.YT.parameters.login=A,t({type:S.wV,data:{login:A}}),u().set((0,h.fc)(e),v),t((a={cluster:e,login:A},function(){var e=(0,s.A)((0,i.A)().mark((function e(t,n){var s;return(0,i.A)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t(V(a.cluster));case 2:return e.next=4,t((0,I.ar)({cluster:a.cluster,path:"",page:""}));case 4:return e.next=6,t((0,w.qP)(a.login));case 6:s=n(),(0,_.pt)(s)||(t((0,w.ZC)(x.Ou.DEVELOPMENT.REDIRECT_TO_BETA_SWITCHED,x.dK.DEVELOPMENT,!0)),t((0,w.ZC)(x.Ou.DEVELOPMENT.REDIRECT_TO_BETA,x.dK.DEVELOPMENT,!0))),(0,_.xS)(s)?t((0,y.cM)("cluster")):t((0,y.Ko)("clusters")),(0,_.AT)(s)?t((0,y.cM)("page")):t((0,y.Ko)("pages")),t((0,y.TG)("cluster",a.cluster));case 11:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}())).then((function(){return t({type:p.pw.FINAL_SUCCESS})})).catch(r)}u().remove((0,h.fc)(e)),t({type:p.pw.FAILURE,data:{errorType:p.NZ.AUTHENTICATION,error:d||new Error("Failed to get CSRF-token")}})}return Promise.resolve()})).catch(r)}}function B(){return function(e){O.YT.parameters.version="",O.YT.cluster="",e({type:S.wV,data:{cluster:void 0}})}}},87604:(e,t,n)=>{n.d(t,{A:()=>_});var i=n(40319),s=n(18801),r=n(29121),o=n(12937),a=n(66134),l=n(10785),c=n(77810),u=n(76872),d=n(73822),g=n(88787),p=n(30513),m=n(64922),h=["items","className"],f=(0,u.A)("elements-radiobutton"),_=function(e){function t(){return(0,r.A)(this,t),(0,a.A)(this,t,arguments)}return(0,l.A)(t,e),(0,o.A)(t,[{key:"render",value:function(){var e=this.props,t=e.items,n=e.className,r=(0,s.A)(e,h);return(0,m.jsx)(p.a,(0,i.A)((0,i.A)({},r),{},{className:f(null,n),children:t.map((function(e){return(0,c.createElement)(p.a.Option,(0,i.A)((0,i.A)({},e),{},{key:e.value}),e.icon&&(0,m.jsx)(g.A,(0,i.A)({},e.icon)),e.text||" "," ")}))}))}}],[{key:"prepareSimpleValue",value:function(e){if(null==e)throw new Error("CustomRadioButton: unexpected value");return{value:e,text:d.A.format.ReadableField(e)}}}])}(c.Component)}}]);
2
- //# sourceMappingURL=settings-panel.4be91fef.chunk.js.map