@itcase/storybook-config 1.2.51 → 1.2.52

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,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import React__default, { useMemo as useMemo$1, createContext, useState, useCallback, useEffect, useContext, useRef, memo, version, isValidElement, useLayoutEffect as useLayoutEffect$1, useReducer, cloneElement, useImperativeHandle } from 'react';
2
+ import React__default, { useMemo as useMemo$1, createContext, useState, useCallback, useEffect, useContext, useRef, memo, version, isValidElement, useLayoutEffect as useLayoutEffect$1, cloneElement, useReducer, useImperativeHandle } from 'react';
3
3
  import camelCase from 'lodash/camelCase';
4
4
  import s$1 from 'lodash/castArray';
5
5
  import i$2 from 'lodash/upperFirst';
@@ -1405,21 +1405,17 @@ function unsafeStringify(arr, offset = 0) {
1405
1405
  byteToHex[arr[offset + 15]]).toLowerCase();
1406
1406
  }
1407
1407
 
1408
- let getRandomValues;
1409
1408
  const rnds8 = new Uint8Array(16);
1410
1409
  function rng() {
1411
- if (!getRandomValues) {
1412
- if (typeof crypto === 'undefined' || !crypto.getRandomValues) {
1413
- throw new Error('crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported');
1414
- }
1415
- getRandomValues = crypto.getRandomValues.bind(crypto);
1416
- }
1417
- return getRandomValues(rnds8);
1410
+ return crypto.getRandomValues(rnds8);
1418
1411
  }
1419
1412
 
1420
- const randomUUID = typeof crypto !== 'undefined' && crypto.randomUUID && crypto.randomUUID.bind(crypto);
1421
- var native = { randomUUID };
1422
-
1413
+ function v4(options, buf, offset) {
1414
+ if (crypto.randomUUID) {
1415
+ return crypto.randomUUID();
1416
+ }
1417
+ return _v4(options);
1418
+ }
1423
1419
  function _v4(options, buf, offset) {
1424
1420
  options = options || {};
1425
1421
  const rnds = options.random ?? options.rng?.() ?? rng();
@@ -1430,12 +1426,6 @@ function _v4(options, buf, offset) {
1430
1426
  rnds[8] = (rnds[8] & 0x3f) | 0x80;
1431
1427
  return unsafeStringify(rnds);
1432
1428
  }
1433
- function v4(options, buf, offset) {
1434
- if (native.randomUUID && true && !options) {
1435
- return native.randomUUID();
1436
- }
1437
- return _v4(options);
1438
- }
1439
1429
 
1440
1430
  const l$1={error:"error",info:"info",success:"success",warning:"warning"},u$3=createContext([]),d$1=createContext({hideNotifications:e=>{},showNotification:(e,o)=>{},notificationStatuses:l$1});function m$2(o){const{initialNotificationsList:s=[],isLogRequestsErrors:c,children:m}=o,[f,g]=useState(()=>(s||[]).map(e=>y$1(e,e.onClose))),p=useCallback(e=>{e&&g(o=>o.filter(o=>{const i=String(o.id)===String(e);return i&&(clearTimeout(o._closeTimeout),o.onClose&&o.onClose()),!i}));},[]),T=useCallback((e,o)=>{const i=y$1(e,o);return g(e=>{const o=e.slice(),t=o.findIndex(e=>String(e.id)===String(i.id));if(-1===t)return [...o,i];const r=o[t];return clearTimeout(r._closeTimeout),r._closeTimeout=void 0,o[t]=i,o}),i.closeByTime&&(i._closeTimeout=setTimeout(()=>p(i.id),i.closeByTime)),i},[]),S=useMemo$1(()=>({hideNotifications:p,notificationStatuses:l$1,showNotification:T}),[]);return useEffect(()=>{f.forEach(e=>{e.closeByTime&&setTimeout(()=>p(e.id),e.closeByTime);}),c&&(axiosInstanceITCase.responseErrorHandler.loggerManager={log:e=>{if(e.message){const o=["network"].includes(e.key)?e.key:void 0;T({id:o,title:e.message,status:"error",closeByTime:4e3});}}});},[]),jsxRuntimeExports.jsx(d$1.Provider,{value:S,children:jsxRuntimeExports.jsx(u$3.Provider,{value:f,children:m})})}function f$2(){return useContext(u$3)}function g$1(){return useContext(d$1)}const p$2={error:"errorPrimary sizeS solid rounded",info:"infoPrimary sizeS solid rounded",success:"successPrimary sizeS solid rounded",warning:"warningPrimary sizeS solid rounded"};function y$1(e,o){let i=v4().split("-")[0],t="",r="",n="",s="",a="float",u="",d=l$1.warning,m=4500,f=p$2[d],g=null,y=false,T="",S=()=>{};return "string"==typeof e?r=e:"object"==typeof e&&(i=String(e.id??i),t=e.title??t,r=e.text??r,T=e.closeIconAppearance??T,a=e.type??a,n=e.closeIcon??n,s=e.closeIconSrc??s,u=e.buttonLabel??u,S=e.onClickButton??S,d=e.status??d,m=e.closeByTime??m,y=e.isLoading??y,g=e.after??g,f=e.appearance??p$2[e.status]??f),{id:i,appearance:f,type:a,title:t,status:d,text:r,buttonLabel:u,after:g,closeByTime:m,closeIcon:n,closeIconAppearance:T,closeIconSrc:s,isLoading:y,onClickButton:S,onClose:o}}
1441
1431
 
@@ -7392,11 +7382,6 @@ async function request(url, options) {
7392
7382
  }
7393
7383
  return response.text();
7394
7384
  }
7395
- function sleep(seconds = 1) {
7396
- return new Promise((resolve) => {
7397
- setTimeout(resolve, seconds * 1e3);
7398
- });
7399
- }
7400
7385
  function supportsInlineSVG() {
7401
7386
  if (!document) {
7402
7387
  return false;
@@ -7409,20 +7394,16 @@ function supportsInlineSVG() {
7409
7394
 
7410
7395
  // src/modules/cache.ts
7411
7396
  var CacheStore = class {
7412
- constructor() {
7397
+ constructor(options = {}) {
7413
7398
  __publicField(this, "cacheApi");
7414
7399
  __publicField(this, "cacheStore");
7415
7400
  __publicField(this, "subscribers", []);
7416
7401
  __publicField(this, "isReady", false);
7402
+ const { name = CACHE_NAME, persistent = false } = options;
7417
7403
  this.cacheStore = /* @__PURE__ */ new Map();
7418
- let cacheName = CACHE_NAME;
7419
- let usePersistentCache = false;
7420
- if (canUseDOM()) {
7421
- cacheName = window.REACT_INLINESVG_CACHE_NAME ?? CACHE_NAME;
7422
- usePersistentCache = !!window.REACT_INLINESVG_PERSISTENT_CACHE && "caches" in window;
7423
- }
7404
+ const usePersistentCache = persistent && canUseDOM() && "caches" in window;
7424
7405
  if (usePersistentCache) {
7425
- caches.open(cacheName).then((cache) => {
7406
+ caches.open(name).then((cache) => {
7426
7407
  this.cacheApi = cache;
7427
7408
  }).catch((error) => {
7428
7409
  console.error(`Failed to open cache: ${error.message}`);
@@ -7446,12 +7427,30 @@ var CacheStore = class {
7446
7427
  onReady(callback) {
7447
7428
  if (this.isReady) {
7448
7429
  callback();
7449
- } else {
7450
- this.subscribers.push(callback);
7430
+ return () => {
7431
+ };
7451
7432
  }
7433
+ this.subscribers.push(callback);
7434
+ return () => {
7435
+ const index = this.subscribers.indexOf(callback);
7436
+ if (index >= 0) {
7437
+ this.subscribers.splice(index, 1);
7438
+ }
7439
+ };
7440
+ }
7441
+ waitForReady() {
7442
+ if (this.isReady) {
7443
+ return Promise.resolve();
7444
+ }
7445
+ return new Promise((resolve) => {
7446
+ this.onReady(resolve);
7447
+ });
7452
7448
  }
7453
7449
  async get(url, fetchOptions) {
7454
- await (this.cacheApi ? this.fetchAndAddToPersistentCache(url, fetchOptions) : this.fetchAndAddToInternalCache(url, fetchOptions));
7450
+ await this.fetchAndCache(url, fetchOptions);
7451
+ return this.cacheStore.get(url)?.content ?? "";
7452
+ }
7453
+ getContent(url) {
7455
7454
  return this.cacheStore.get(url)?.content ?? "";
7456
7455
  }
7457
7456
  set(url, data) {
@@ -7460,57 +7459,44 @@ var CacheStore = class {
7460
7459
  isCached(url) {
7461
7460
  return this.cacheStore.get(url)?.status === STATUS.LOADED;
7462
7461
  }
7463
- async fetchAndAddToInternalCache(url, fetchOptions) {
7464
- const cache = this.cacheStore.get(url);
7465
- if (cache?.status === STATUS.LOADING) {
7466
- await this.handleLoading(url, async () => {
7467
- this.cacheStore.set(url, { content: "", status: STATUS.IDLE });
7468
- await this.fetchAndAddToInternalCache(url, fetchOptions);
7469
- });
7470
- return;
7462
+ async fetchAndCache(url, fetchOptions) {
7463
+ if (!this.isReady) {
7464
+ await this.waitForReady();
7471
7465
  }
7472
- if (!cache?.content) {
7473
- this.cacheStore.set(url, { content: "", status: STATUS.LOADING });
7474
- try {
7475
- const content = await request(url, fetchOptions);
7476
- this.cacheStore.set(url, { content, status: STATUS.LOADED });
7477
- } catch (error) {
7478
- this.cacheStore.set(url, { content: "", status: STATUS.FAILED });
7479
- throw error;
7480
- }
7481
- }
7482
- }
7483
- async fetchAndAddToPersistentCache(url, fetchOptions) {
7484
7466
  const cache = this.cacheStore.get(url);
7485
7467
  if (cache?.status === STATUS.LOADED) {
7486
7468
  return;
7487
7469
  }
7488
7470
  if (cache?.status === STATUS.LOADING) {
7489
- await this.handleLoading(url, async () => {
7471
+ await this.handleLoading(url, fetchOptions?.signal || void 0, async () => {
7490
7472
  this.cacheStore.set(url, { content: "", status: STATUS.IDLE });
7491
- await this.fetchAndAddToPersistentCache(url, fetchOptions);
7473
+ await this.fetchAndCache(url, fetchOptions);
7492
7474
  });
7493
7475
  return;
7494
7476
  }
7495
7477
  this.cacheStore.set(url, { content: "", status: STATUS.LOADING });
7496
- const data = await this.cacheApi?.match(url);
7497
- if (data) {
7498
- const content = await data.text();
7499
- this.cacheStore.set(url, { content, status: STATUS.LOADED });
7500
- return;
7501
- }
7502
7478
  try {
7503
- await this.cacheApi?.add(new Request(url, fetchOptions));
7504
- const response = await this.cacheApi?.match(url);
7505
- const content = await response?.text() ?? "";
7479
+ const content = this.cacheApi ? await this.fetchFromPersistentCache(url, fetchOptions) : await request(url, fetchOptions);
7506
7480
  this.cacheStore.set(url, { content, status: STATUS.LOADED });
7507
7481
  } catch (error) {
7508
7482
  this.cacheStore.set(url, { content: "", status: STATUS.FAILED });
7509
7483
  throw error;
7510
7484
  }
7511
7485
  }
7512
- async handleLoading(url, callback) {
7486
+ async fetchFromPersistentCache(url, fetchOptions) {
7487
+ const data = await this.cacheApi?.match(url);
7488
+ if (data) {
7489
+ return data.text();
7490
+ }
7491
+ await this.cacheApi?.add(new Request(url, fetchOptions));
7492
+ const response = await this.cacheApi?.match(url);
7493
+ return await response?.text() ?? "";
7494
+ }
7495
+ async handleLoading(url, signal, callback) {
7513
7496
  for (let retryCount = 0; retryCount < CACHE_MAX_RETRIES; retryCount++) {
7497
+ if (signal?.aborted) {
7498
+ throw signal.reason instanceof Error ? signal.reason : new DOMException("The operation was aborted.", "AbortError");
7499
+ }
7514
7500
  if (this.cacheStore.get(url)?.status !== STATUS.LOADING) {
7515
7501
  return;
7516
7502
  }
@@ -7538,6 +7524,14 @@ var CacheStore = class {
7538
7524
  this.cacheStore.clear();
7539
7525
  }
7540
7526
  };
7527
+ function sleep(seconds = 1) {
7528
+ return new Promise((resolve) => {
7529
+ setTimeout(resolve, seconds * 1e3);
7530
+ });
7531
+ }
7532
+ function useMount(effect) {
7533
+ useEffect(effect, []);
7534
+ }
7541
7535
  function usePrevious(state) {
7542
7536
  const ref = useRef(void 0);
7543
7537
  useEffect(() => {
@@ -7545,6 +7539,29 @@ function usePrevious(state) {
7545
7539
  });
7546
7540
  return ref.current;
7547
7541
  }
7542
+ function uniquifyStyleIds(svgText, hash, baseURL) {
7543
+ const idMatches = svgText.matchAll(/\bid=(["'])([^"']+)\1/g);
7544
+ const ids = [...new Set([...idMatches].map((m) => m[2]))];
7545
+ if (!ids.length) {
7546
+ return svgText;
7547
+ }
7548
+ ids.sort((a, b) => b.length - a.length);
7549
+ return svgText.replace(/<style[^>]*>([\S\s]*?)<\/style>/gi, (fullMatch, cssContent) => {
7550
+ let modified = cssContent;
7551
+ for (const id of ids) {
7552
+ const escaped = id.replace(/[$()*+.?[\\\]^{|}]/g, "\\$&");
7553
+ modified = modified.replace(
7554
+ new RegExp(`url\\((['"]?)#${escaped}\\1\\)`, "g"),
7555
+ `url($1${baseURL}#${id}__${hash}$1)`
7556
+ );
7557
+ modified = modified.replace(
7558
+ new RegExp(`#${escaped}(?![a-zA-Z0-9_-])`, "g"),
7559
+ `#${id}__${hash}`
7560
+ );
7561
+ }
7562
+ return fullMatch.replace(cssContent, modified);
7563
+ });
7564
+ }
7548
7565
  function getNode(options) {
7549
7566
  const {
7550
7567
  baseURL,
@@ -7557,7 +7574,10 @@ function getNode(options) {
7557
7574
  uniquifyIDs = false
7558
7575
  } = options;
7559
7576
  try {
7560
- const svgText = processSVG(content, preProcessor);
7577
+ let svgText = processSVG(content, preProcessor);
7578
+ if (uniquifyIDs) {
7579
+ svgText = uniquifyStyleIds(svgText, hash, baseURL ?? "");
7580
+ }
7561
7581
  const node = convert(svgText, { nodeOnly: true });
7562
7582
  if (!node || !(node instanceof SVGSVGElement)) {
7563
7583
  throw new Error("Could not convert the src to a DOM Node");
@@ -7627,22 +7647,30 @@ function updateSVGAttributes(node, options) {
7627
7647
  return node;
7628
7648
  }
7629
7649
 
7630
- // src/index.tsx
7631
- var cacheStore;
7632
- function ReactInlineSVG(props) {
7650
+ // src/modules/useInlineSVG.ts
7651
+ function useInlineSVG(props, cacheStore2) {
7633
7652
  const {
7653
+ baseURL,
7634
7654
  cacheRequests = true,
7635
- children = null,
7636
7655
  description,
7637
7656
  fetchOptions,
7638
- innerRef,
7639
- loader = null,
7640
7657
  onError,
7641
7658
  onLoad,
7659
+ preProcessor,
7642
7660
  src,
7643
7661
  title,
7644
- uniqueHash
7662
+ uniqueHash,
7663
+ uniquifyIDs
7645
7664
  } = props;
7665
+ const hash = useRef(uniqueHash ?? randomString(8));
7666
+ const fetchOptionsRef = useRef(fetchOptions);
7667
+ const onErrorRef = useRef(onError);
7668
+ const onLoadRef = useRef(onLoad);
7669
+ const preProcessorRef = useRef(preProcessor);
7670
+ fetchOptionsRef.current = fetchOptions;
7671
+ onErrorRef.current = onError;
7672
+ onLoadRef.current = onLoad;
7673
+ preProcessorRef.current = preProcessor;
7646
7674
  const [state, setState] = useReducer(
7647
7675
  (previousState2, nextState) => ({
7648
7676
  ...previousState2,
@@ -7651,43 +7679,71 @@ function ReactInlineSVG(props) {
7651
7679
  {
7652
7680
  content: "",
7653
7681
  element: null,
7654
- isCached: cacheRequests && cacheStore.isCached(props.src),
7682
+ isCached: false,
7655
7683
  status: STATUS.IDLE
7684
+ },
7685
+ (initial) => {
7686
+ const cached = cacheRequests && cacheStore2.isCached(src);
7687
+ if (!cached) {
7688
+ return initial;
7689
+ }
7690
+ const cachedContent = cacheStore2.getContent(src);
7691
+ try {
7692
+ const node = getNode({
7693
+ ...props,
7694
+ handleError: () => {
7695
+ },
7696
+ hash: hash.current,
7697
+ content: cachedContent
7698
+ });
7699
+ if (!node) {
7700
+ return { ...initial, content: cachedContent, isCached: true, status: STATUS.LOADED };
7701
+ }
7702
+ const convertedElement = convert(node);
7703
+ if (convertedElement && isValidElement(convertedElement)) {
7704
+ return {
7705
+ content: cachedContent,
7706
+ element: convertedElement,
7707
+ isCached: true,
7708
+ status: STATUS.READY
7709
+ };
7710
+ }
7711
+ } catch {
7712
+ }
7713
+ return {
7714
+ ...initial,
7715
+ content: cachedContent,
7716
+ isCached: true,
7717
+ status: STATUS.LOADED
7718
+ };
7656
7719
  }
7657
7720
  );
7658
7721
  const { content, element, isCached, status } = state;
7659
7722
  const previousProps = usePrevious(props);
7660
7723
  const previousState = usePrevious(state);
7661
- const hash = useRef(uniqueHash ?? randomString(8));
7662
7724
  const isActive = useRef(false);
7663
7725
  const isInitialized = useRef(false);
7664
- const handleError = useCallback(
7665
- (error) => {
7666
- if (isActive.current) {
7667
- setState({
7668
- status: error.message === "Browser does not support SVG" ? STATUS.UNSUPPORTED : STATUS.FAILED
7669
- });
7670
- onError?.(error);
7671
- }
7672
- },
7673
- [onError]
7674
- );
7675
- const handleLoad = useCallback((loadedContent, hasCache = false) => {
7726
+ const handleError = useCallback((error) => {
7676
7727
  if (isActive.current) {
7677
7728
  setState({
7678
- content: loadedContent,
7679
- isCached: hasCache,
7680
- status: STATUS.LOADED
7729
+ status: error.message === "Browser does not support SVG" ? STATUS.UNSUPPORTED : STATUS.FAILED
7681
7730
  });
7731
+ onErrorRef.current?.(error);
7682
7732
  }
7683
7733
  }, []);
7684
- const fetchContent = useCallback(async () => {
7685
- const responseContent = await request(src, fetchOptions);
7686
- handleLoad(responseContent);
7687
- }, [fetchOptions, handleLoad, src]);
7688
7734
  const getElement = useCallback(() => {
7689
7735
  try {
7690
- const node = getNode({ ...props, handleError, hash: hash.current, content });
7736
+ const node = getNode({
7737
+ baseURL,
7738
+ content,
7739
+ description,
7740
+ handleError,
7741
+ hash: hash.current,
7742
+ preProcessor: preProcessorRef.current,
7743
+ src,
7744
+ title,
7745
+ uniquifyIDs
7746
+ });
7691
7747
  const convertedElement = convert(node);
7692
7748
  if (!convertedElement || !isValidElement(convertedElement)) {
7693
7749
  throw new Error("Could not convert the src to a React element");
@@ -7699,67 +7755,32 @@ function ReactInlineSVG(props) {
7699
7755
  } catch (error) {
7700
7756
  handleError(error);
7701
7757
  }
7702
- }, [content, handleError, props]);
7703
- const getContent = useCallback(async () => {
7704
- const dataURI = /^data:image\/svg[^,]*?(;base64)?,(.*)/u.exec(src);
7705
- let inlineSrc;
7706
- if (dataURI) {
7707
- inlineSrc = dataURI[1] ? window.atob(dataURI[2]) : decodeURIComponent(dataURI[2]);
7708
- } else if (src.includes("<svg")) {
7709
- inlineSrc = src;
7710
- }
7711
- if (inlineSrc) {
7712
- handleLoad(inlineSrc);
7713
- return;
7758
+ }, [baseURL, content, description, handleError, src, title, uniquifyIDs]);
7759
+ useMount(() => {
7760
+ isActive.current = true;
7761
+ if (!canUseDOM() || isInitialized.current) {
7762
+ return void 0;
7714
7763
  }
7715
7764
  try {
7716
- if (cacheRequests) {
7717
- const cachedContent = await cacheStore.get(src, fetchOptions);
7718
- handleLoad(cachedContent, true);
7719
- } else {
7720
- await fetchContent();
7765
+ if (status === STATUS.READY) {
7766
+ onLoadRef.current?.(src, isCached);
7767
+ } else if (status === STATUS.IDLE) {
7768
+ if (!isSupportedEnvironment()) {
7769
+ throw new Error("Browser does not support SVG");
7770
+ }
7771
+ if (!src) {
7772
+ throw new Error("Missing src");
7773
+ }
7774
+ setState({ content: "", element: null, isCached: false, status: STATUS.LOADING });
7721
7775
  }
7722
7776
  } catch (error) {
7723
7777
  handleError(error);
7724
7778
  }
7725
- }, [cacheRequests, fetchContent, fetchOptions, handleError, handleLoad, src]);
7726
- const load = useCallback(async () => {
7727
- if (isActive.current) {
7728
- setState({
7729
- content: "",
7730
- element: null,
7731
- isCached: false,
7732
- status: STATUS.LOADING
7733
- });
7734
- }
7735
- }, []);
7736
- useEffect(
7737
- () => {
7738
- isActive.current = true;
7739
- if (!canUseDOM() || isInitialized.current) {
7740
- return void 0;
7741
- }
7742
- try {
7743
- if (status === STATUS.IDLE) {
7744
- if (!isSupportedEnvironment()) {
7745
- throw new Error("Browser does not support SVG");
7746
- }
7747
- if (!src) {
7748
- throw new Error("Missing src");
7749
- }
7750
- load();
7751
- }
7752
- } catch (error) {
7753
- handleError(error);
7754
- }
7755
- isInitialized.current = true;
7756
- return () => {
7757
- isActive.current = false;
7758
- };
7759
- },
7760
- // eslint-disable-next-line react-hooks/exhaustive-deps
7761
- []
7762
- );
7779
+ isInitialized.current = true;
7780
+ return () => {
7781
+ isActive.current = false;
7782
+ };
7783
+ });
7763
7784
  useEffect(() => {
7764
7785
  if (!canUseDOM() || !previousProps) {
7765
7786
  return;
@@ -7769,14 +7790,58 @@ function ReactInlineSVG(props) {
7769
7790
  handleError(new Error("Missing src"));
7770
7791
  return;
7771
7792
  }
7772
- load();
7793
+ setState({ content: "", element: null, isCached: false, status: STATUS.LOADING });
7773
7794
  }
7774
- }, [handleError, load, previousProps, src]);
7795
+ }, [handleError, previousProps, src]);
7775
7796
  useEffect(() => {
7776
- if (status === STATUS.LOADED) {
7797
+ if (status !== STATUS.LOADING) {
7798
+ return void 0;
7799
+ }
7800
+ const controller = new AbortController();
7801
+ let active = true;
7802
+ (async () => {
7803
+ try {
7804
+ const dataURI = /^data:image\/svg[^,]*?(;base64)?,(.*)/.exec(src);
7805
+ let inlineSrc;
7806
+ if (dataURI) {
7807
+ inlineSrc = dataURI[1] ? window.atob(dataURI[2]) : decodeURIComponent(dataURI[2]);
7808
+ } else if (src.includes("<svg")) {
7809
+ inlineSrc = src;
7810
+ }
7811
+ if (inlineSrc) {
7812
+ if (active) {
7813
+ setState({ content: inlineSrc, isCached: false, status: STATUS.LOADED });
7814
+ }
7815
+ return;
7816
+ }
7817
+ const fetchParameters = { ...fetchOptionsRef.current, signal: controller.signal };
7818
+ let loadedContent;
7819
+ let hasCache = false;
7820
+ if (cacheRequests) {
7821
+ hasCache = cacheStore2.isCached(src);
7822
+ loadedContent = await cacheStore2.get(src, fetchParameters);
7823
+ } else {
7824
+ loadedContent = await request(src, fetchParameters);
7825
+ }
7826
+ if (active) {
7827
+ setState({ content: loadedContent, isCached: hasCache, status: STATUS.LOADED });
7828
+ }
7829
+ } catch (error) {
7830
+ if (active && error.name !== "AbortError") {
7831
+ handleError(error);
7832
+ }
7833
+ }
7834
+ })();
7835
+ return () => {
7836
+ active = false;
7837
+ controller.abort();
7838
+ };
7839
+ }, [cacheRequests, cacheStore2, handleError, src, status]);
7840
+ useEffect(() => {
7841
+ if (status === STATUS.LOADED && content) {
7777
7842
  getElement();
7778
7843
  }
7779
- }, [status, getElement]);
7844
+ }, [content, getElement, status]);
7780
7845
  useEffect(() => {
7781
7846
  if (!canUseDOM() || !previousProps || previousProps.src !== src) {
7782
7847
  return;
@@ -7789,51 +7854,47 @@ function ReactInlineSVG(props) {
7789
7854
  if (!previousState) {
7790
7855
  return;
7791
7856
  }
7792
- switch (status) {
7793
- case STATUS.LOADING: {
7794
- if (previousState.status !== STATUS.LOADING) {
7795
- getContent();
7796
- }
7797
- break;
7798
- }
7799
- case STATUS.LOADED: {
7800
- if (previousState.status !== STATUS.LOADED) {
7801
- getElement();
7802
- }
7803
- break;
7804
- }
7805
- case STATUS.READY: {
7806
- if (previousState.status !== STATUS.READY) {
7807
- onLoad?.(src, isCached);
7808
- }
7809
- break;
7810
- }
7857
+ if (status === STATUS.READY && previousState.status !== STATUS.READY) {
7858
+ onLoadRef.current?.(src, isCached);
7811
7859
  }
7812
- }, [getContent, getElement, isCached, onLoad, previousState, src, status]);
7813
- const elementProps = omit(
7814
- props,
7815
- "baseURL",
7816
- "cacheRequests",
7817
- "children",
7818
- "description",
7819
- "fetchOptions",
7820
- "innerRef",
7821
- "loader",
7822
- "onError",
7823
- "onLoad",
7824
- "preProcessor",
7825
- "src",
7826
- "title",
7827
- "uniqueHash",
7828
- "uniquifyIDs"
7829
- );
7860
+ }, [isCached, previousState, src, status]);
7861
+ return { element, status };
7862
+ }
7863
+ var CacheContext = createContext(null);
7864
+ function useCacheStore() {
7865
+ return useContext(CacheContext);
7866
+ }
7867
+
7868
+ // src/index.tsx
7869
+ var cacheStore = new CacheStore();
7870
+ function InlineSVG(props) {
7871
+ const { children = null, innerRef, loader = null } = props;
7872
+ const contextStore = useCacheStore();
7873
+ const store = contextStore ?? cacheStore;
7874
+ const { element, status } = useInlineSVG(props, store);
7830
7875
  if (!canUseDOM()) {
7831
7876
  return loader;
7832
7877
  }
7833
7878
  if (element) {
7834
7879
  return cloneElement(element, {
7835
7880
  ref: innerRef,
7836
- ...elementProps
7881
+ ...omit(
7882
+ props,
7883
+ "baseURL",
7884
+ "cacheRequests",
7885
+ "children",
7886
+ "description",
7887
+ "fetchOptions",
7888
+ "innerRef",
7889
+ "loader",
7890
+ "onError",
7891
+ "onLoad",
7892
+ "preProcessor",
7893
+ "src",
7894
+ "title",
7895
+ "uniqueHash",
7896
+ "uniquifyIDs"
7897
+ )
7837
7898
  });
7838
7899
  }
7839
7900
  if ([STATUS.UNSUPPORTED, STATUS.FAILED].includes(status)) {
@@ -7841,33 +7902,14 @@ function ReactInlineSVG(props) {
7841
7902
  }
7842
7903
  return loader;
7843
7904
  }
7844
- function InlineSVG(props) {
7845
- if (!cacheStore) {
7846
- cacheStore = new CacheStore();
7847
- }
7848
- const { loader } = props;
7849
- const [isReady, setReady] = useState(cacheStore.isReady);
7850
- useEffect(() => {
7851
- if (isReady) {
7852
- return;
7853
- }
7854
- cacheStore.onReady(() => {
7855
- setReady(true);
7856
- });
7857
- }, [isReady]);
7858
- if (!isReady) {
7859
- return loader;
7860
- }
7861
- return /* @__PURE__ */ React__default.createElement(ReactInlineSVG, { ...props });
7862
- }
7863
7905
 
7864
7906
  const o=["src","imageSrc","svgSrc","placeholderUrl"],f$1=(f,...a)=>React__default.forwardRef(function(r,a){const{assetPrefix:c,ignorePathsList:m}=useContext(i),p=o.reduce((t,e)=>{let i=r[e];if(i&&"string"==typeof i){if(c){if(n(i,c,m)){i=`${formatURL(c).slice(0,-1)}${i}`;}}t[e]=i;}return t},{});return jsxRuntimeExports.jsx(f,{...r,...p,ref:a})}),n=(t,r,e=[])=>{if(t.startsWith("http:")||t.startsWith("https:")||t.startsWith("data:")||t.startsWith(r))return false;for(const r of e)if(r instanceof RegExp){if(r.test(t))return false}else if(formatURL(t).startsWith(formatURL(r)))return false;return true};
7865
7907
 
7866
- const z={sizeXXL:{size:"xxl"},sizeXL:{size:"xl"},sizeL:{size:"l"},sizeM:{size:"m"},sizeS:{size:"s"},sizeXS:{size:"xs"},sizeXXS:{size:"xxs"}},u={appearance:z};function _$1(r){const{appearance:i,className:a,dataTestId:o,dataTour:l,cursor:t,style:s,tag:n="span",before:c,after:S,isActive:p,isDisabled:x,isSkeleton:z,onClick:_,onDoubleClick:b,children:g}=r,C=e$1(i,u,x),v=u$1(r,C),{textAlignClass:P,textColorActiveClass:T,textColorActiveHoverClass:h,textColorClass:H,textColorDisabledClass:A,textColorHoverClass:B,textFontClass:$,textStyleClass:w,textTruncateClass:F,textWeightClass:X,textWrapClass:I,cursorClass:k,sizeClass:N,widthClass:Q}=v,{styles:L}=c$1(r);return jsxRuntimeExports.jsxs(n,{className:clsx(a,"text",N&&`text_size_${N}`,X&&`text-weight_${X}`,P&&`text-align_${P}`,x&&A&&`text-color_${A}`,!p&&!x&&H&&`text-color_${H}`,!p&&!x&&B&&`text-color_hover_${B}`,p&&!x&&h&&`text-color_active_hover_${h}`,p&&!x&&T&&`text-color_active_${T}`,$&&`text-font_${$}`,w&&`text-style_${w}`,I&&`word-wrap_${I}`,F&&`text-truncate_${F}`,z&&"skeleton",Q&&`width_${Q}`,k&&`cursor_${k}`,_&&(t||"cursor_type_pointer")),"data-testid":o,"data-tour":l,style:Object.assign({},L,s),onClick:_,onDoubleClick:b,children:[c,g,S]})}const b$1={sizeXXL:{size:"xxl",textSize:"xl",iconSize:"24"},sizeXL:{size:"xl",textSize:"l",iconSize:"24"},sizeL:{size:"l",textSize:"l",iconSize:"24"},sizeM:{size:"m",textSize:"m",iconSize:"24"},sizeS:{size:"s",textSize:"s",iconSize:"24"},sizeXS:{size:"xs",textSize:"xs",iconSize:"24"},sizeXXS:{size:"xxs",textSize:"xs",iconSize:"24"},circular:{shape:"circular"},rounded:{shape:"rounded"},roundedXL:{shape:"rounded"},roundedL:{shape:"rounded"},roundedM:{shape:"rounded"},roundedS:{shape:"rounded"},solid:{borderColor:"none"},outlined:{fill:"none"},full:{},ghost:{fill:"none",borderColor:"none"},accentPrimary:{fill:"accentPrimary",borderColor:"accentBorderQuaternary",textColor:"accentTextPrimary",dotFill:"accentItemPrimary",iconFill:"accentItemPrimary"},accentQuaternary:{fill:"accentQuaternary",borderColor:"accentBorderQuaternary",textColor:"accentTextPrimary",dotFill:"accentItemPrimary",iconFill:"accentItemPrimary"},accentSecondary:{fill:"accentSecondary",borderColor:"accentBorderQuaternary",textColor:"accentTextQuaternary",dotFill:"accentItemQuaternary",iconFill:"accentItemQuaternary"},accentTertiary:{fill:"accentTertiary",borderColor:"accentBorderSecondary",textColor:"accentTextSecondary",dotFill:"accentItemSecondary",iconFill:"accentItemSecondary"},dangerPrimary:{fill:"dangerPrimary",borderColor:"dangerBorderPrimary",textColor:"dangerTextPrimary",dotFill:"dangerItemPrimary",iconFill:"dangerItemPrimary"},errorPrimary:{fill:"errorPrimary",fillHover:"errorHoverPrimary",textColor:"errorTextPrimary",iconFill:"errorItemPrimary"},infoPrimary:{fill:"infoPrimary",borderColor:"infoBorderSecondary",textColor:"infoTextPrimary",dotFill:"infoItemPrimary",iconFill:"infoItemPrimary"},infoSecondary:{fill:"infoSecondary",borderColor:"infoBorderSecondary",textColor:"infoTextSecondary",dotFill:"infoItemSecondary"},specialPrimary:{fill:"specialPrimary",borderColor:"specialBorderSecondary",textColor:"specialTextPrimary",dotFill:"specialItemPrimary",iconFill:"specialItemPrimary"},extraPrimary:{fill:"extraPrimary",borderColor:"extraBorderSecondary",textColor:"extraTextPrimary",dotFill:"extraItemPrimary",iconFill:"extraItemPrimary"},successPrimary:{fill:"successPrimary",borderColor:"successBorderPrimary",textColor:"successTextPrimary",dotFill:"successItemPrimary",iconFill:"successItemPrimary"},disabledPrimary:{fill:"surfacePrimary",borderColor:"surfaceBorderPrimary",textColor:"surfaceTextPrimary",iconFill:"surfaceItemPrimary"},surfacePrimary:{fill:"surfacePrimary",borderColor:"surfaceBorderTertiary",textColor:"surfaceTextPrimary",dotFill:"surfaceItemPrimary",iconFill:"surfaceItemPrimary"},surfaceQuaternary:{fill:"accentPrimary",borderColor:"surfaceBorderPrimary",textColor:"surfaceTextPrimary"},surfaceSecondary:{fill:"surfaceSecondary",borderColor:"surfaceBorderSecondary",textColor:"surfaceTextPrimary"},surfaceTertiary:{fill:"surfaceTertiary",borderColor:"surfaceBorderTertiary",textColor:"surfaceTextPrimary"},warningPrimary:{fill:"warningPrimary",borderColor:"warningBorderPrimary",textColor:"warningTextPrimary",dotFill:"warningItemPrimary",iconFill:"warningItemPrimary"}},g={appearance:b$1};function C(i){const{appearance:a,className:o,dataTestId:l,dataTour:t,dot:s,icon:n,iconSrc:c,value:S,isSkeleton:p,children:x}=i,z=e$1(a,g),u=u$1(i,z),{fillClass:b,fillHoverClass:C,borderColorClass:v,borderColorHoverClass:P,borderTypeClass:T,borderWidthClass:h,textColor:H,textSize:A,dotFillClass:B,iconFill:$,iconShape:w,iconSize:F,shapeClass:X,sizeClass:I}=u,{styles:k}=c$1(i);return jsxRuntimeExports.jsxs("div",{className:clsx(o,"badge",v&&`border-color_${v}`,P&&`border-color_hover_${P}`,h&&`border-width_${h}`,T&&`border_type_${T}`,b&&`fill_${b}`,C&&`fill_hover_${C}`,I&&`badge_size_${I}`,X&&`shape_${X}`,S?n?s?"badge_type_dot-icon-counter":"badge_type_icon-counter":"badge_type_counter":n?"badge_type_icon":s?"badge_type_dot":"badge_type_fill",p&&"skeleton"),"data-testid":l,"data-tour":t,style:k,children:[s&&jsxRuntimeExports.jsx("div",{className:clsx("badge__dot",B&&`svg_fill_${B}`),children:jsxRuntimeExports.jsx("svg",{width:"6",height:"6",viewBox:"0 0 6 6",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntimeExports.jsx("rect",{width:"6",height:"6",rx:"50"})})}),n&&jsxRuntimeExports.jsx(N,{className:"badge__icon",size:F,iconFill:$,imageSrc:c,shape:w,SvgImage:n}),x||S&&jsxRuntimeExports.jsx(_$1,{className:"badge__value",size:A,textColor:H,children:S})]})}const P$2={LinkComponent:"a"};function h(e){const{href:i,LinkComponent:o,rel:l,target:t,children:s,...n}=e;if(i){const e=o||P$2.LinkComponent;return jsxRuntimeExports.jsx(e,{href:i,rel:l,target:t,...n,children:s})}else if(o)return jsxRuntimeExports.jsx(o,{...n,children:s});return React__default.Children.toArray(s).filter(Boolean).map(e=>React__default.isValidElement(e)?React__default.cloneElement(e,n):e)}const H={h1:{size:"h1",iconAfterFillSize:"24",iconAfterSize:"24",iconBeforeFillSize:"24",iconBeforeSize:"24"},h2:{size:"h2",iconAfterFillSize:"24",iconAfterSize:"24",iconBeforeFillSize:"24",iconBeforeSize:"24"},h3:{size:"h3",iconAfterFillSize:"24",iconAfterSize:"24",iconBeforeFillSize:"24",iconBeforeSize:"24"},h4:{size:"h4",iconAfterFillSize:"24",iconAfterSize:"24",iconBeforeFillSize:"24",iconBeforeSize:"24"},h5:{size:"h5",iconAfterFillSize:"20",iconAfterSize:"20",iconBeforeFillSize:"20",iconBeforeSize:"20"},h6:{size:"h6",iconAfterFillSize:"16",iconAfterSize:"16",iconBeforeFillSize:"16",iconBeforeSize:"16"},disabledPrimary:{fill:"surfacePrimary",borderColor:"errorBorderQuaternary",borderHover:"errorBorderHoverQuaternary",textColor:"surfaceTextQuaternary",iconBeforeFill:"errorQuaternary"},disabledSecondary:{fill:"surfaceSecondary",borderColor:"surfaceBorderTertiary",borderHover:"surfaceBorderHoverQuaternary",iconBeforeFill:"surfaceQuaternary"},solid:{},outlined:{fill:"none"},full:{},ghost:{fill:"none"},accentPrimary:{fill:"accentPrimary",fillHover:"accentHoverPrimary"},accentSecondary:{fill:"accentPrimary",fillHover:"accentHoverPrimary"},dangerPrimary:{fill:"dangerPrimary",fillHover:"dangerHoverPrimary"},errorPrimary:{fill:"errorPrimary",fillHover:"errorHoverPrimary",textColor:"errorTextPrimary",textColorHover:"errorTextPrimary"},infoPrimary:{fill:"accentPrimary",fillHover:"accentHoverPrimary"},infoSecondary:{fill:"accentPrimary",fillHover:"accentHoverPrimary"},specialPrimary:{fill:"specialPrimary",fillHover:"specialHoverPrimary"},extraPrimary:{fill:"extraPrimary",fillHover:"extraHoverPrimary",textColor:"extraTextPrimary"},successPrimary:{fill:"successPrimary",fillHover:"successHoverPrimary"},surfacePrimary:{fill:"surfacePrimary",fillHover:"surfaceHoverPrimary"},surfaceQuaternary:{fill:"surfaceQuaternary",fillHover:"surfaceHoverQuaternary"},surfaceSecondary:{fill:"surfaceSecondary",fillHover:"surfaceHoverSecondary"},surfaceTertiary:{fill:"surfaceTertiary",fillHover:"surfaceHoverTertiary"},warningPrimary:{fill:"warningPrimary",fillHover:"warningHoverPrimary",textColor:"warningTextSecondary",textColorHover:"warningTextSecondary"},requirePrimary:{fill:"warningTertiary",borderColor:"warningBorderQuaternary",borderHover:"warningBorderQuaternary",textColor:"surfaceTextPrimary",iconBeforeFill:"warningQuaternary"},requireSecondary:{fill:"surfaceSecondary",borderColor:"surfaceBorderTertiary",borderHover:"surfaceBorderQuaternary",iconBeforeFill:"surfaceQuaternary"}},A={appearance:H};function B(i){const{appearance:a,className:l,dataTestId:t,dataTour:s,text:n,afterWrapper:c,beforeWrapper:S,style:p,tag:x="span",before:z,after:u,isActive:_,isDisabled:b,isSkeleton:g,onClick:C,children:v}=i,P=e$1(a,A,b),T=u$1(i,P),{directionClass:h,size:H,fillClass:B,fillHoverClass:$,textAlignClass:w,textColorActiveClass:F,textColorActiveHoverClass:X,textColorClass:I,textColorDisabledClass:k,textColorHoverClass:Q,textFontClass:L,textStyleClass:D,textTruncateClass:M,textWeightClass:W,textWrap:V,heightClass:E,iconAfter:O,iconAfterFill:j,iconAfterFillIcon:q,iconAfterFillSize:G,iconAfterShape:R,iconAfterSize:U,iconAfterSrc:J,iconBadgeAppearance:K,iconBadgeShape:Y,iconBadgeSize:Z,iconBadgeTextColor:ee,iconBadgeTextSize:re,iconBadgeValue:ie,iconBefore:ae,iconBeforeFill:oe,iconBeforeFillIcon:le,iconBeforeFillSize:te,iconBeforeShape:se,iconBeforeSize:ne,iconBeforeSrc:ce,svgFillClass:de,svgFillHoverClass:fe,widthClass:ye,wrapperDirectionClass:me,onClickIconAfter:Se,onClickIconBefore:pe}=T,{styles:xe,wrapper:ze}=c$1(i),ue=useMemo$1(()=>x||(H||"span"),[x,H]);return jsxRuntimeExports.jsxs(ue,{className:clsx(l,"title",B&&`fill_${B}`,$&&`fill_hover_${$}`,de&&`svg_fill_${de}`,fe&&`svg_fill_hover_${fe}`,ye&&`width_${ye}`,E&&`height_${E}`,H&&`title_size_${H}`,h&&`title_direction_${h}`,b&&k&&`text-color_${k}`,!_&&!b&&I&&`text text-color_${I}`,_&&!b&&F&&`text-color_active_${F}`,!_&&!b&&Q&&`text-color_hover_${Q}`,_&&!b&&X&&`text-color_active_hover${X}`,L&&`text-font_${L}`,D&&`text-style_${D}`,W&&`text-weight_${W}`,V&&`word-wrap_${V}`,ie&&"title_badge",g&&"skeleton"),"data-testid":t,"data-tour":s,style:Object.assign({},xe,p),onClick:C,children:[z,jsxRuntimeExports.jsxs("span",{className:clsx(w&&`text-align_${w}`,me&&`title_direction_${me}`,"title__wrapper",M&&`text-truncate_${M}`),style:ze,children:[(ae||ce)&&jsxRuntimeExports.jsx(N,{className:clsx("title__icon_before",ie&&"title__icon_before-badge"),fill:oe,fillSize:te,badgeAppearance:K,badgeClass:"title__icon_before_badge",badgeShape:Y,badgeSize:Z,badgeTextColor:ee,badgeTextSize:re,badgeValue:ie,iconFill:le,iconSize:ne,imageSrc:ce,shape:se,SvgImage:ae,onClick:pe}),S,v||n,c,(O||J)&&jsxRuntimeExports.jsx(N,{className:clsx("title__icon_after",ie&&"title__icon_after-badge"),fill:j,fillSize:G,badgeAppearance:K,badgeClass:"title__icon_after_badge",badgeShape:Y,badgeSize:Z,badgeTextColor:ee,badgeTextSize:re,badgeValue:ie,iconFill:q,iconSize:U,imageSrc:J,shape:R,SvgImage:O,onClick:Se})]}),u]})}const $={defaultPrimary:{fill:"surfacePrimary",fillHover:"surfaceHoverPrimary",titleColor:"surfaceTextPrimary",borderColor:"surfaceBorderPrimary",textColor:"surfaceTextPrimary"},sizeL:{size:"l",titleSize:"h5",textSize:"s"},sizeM:{size:"m",titleSize:"h5",textSize:"s"},sizeS:{size:"s",titleSize:"h5",textSize:"s"},disabledPrimary:{fill:"disabledPrimary",fillHover:"disabledHoverPrimary",titleColor:"surfaceTextPrimary",textColor:"surfaceTextPrimary"},requirePrimary:{fill:"warningPrimary",fillHover:"warningHoverPrimary",titleColor:"warningTextPrimary",borderColor:"warningBorderPrimary",textColor:"warningTextPrimary"},circular:{shape:"circular"},rounded:{shape:"rounded"},roundedXL:{shape:"rounded"},roundedL:{shape:"rounded"},roundedM:{shape:"rounded"},roundedS:{shape:"rounded"},solid:{borderColor:"none"},outlined:{fill:"none"},full:{},ghost:{fill:"none",borderColor:"none"},errorPrimary:{fill:"errorPrimary",fillHover:"errorHoverPrimary",titleColor:"errorTextPrimary",borderColor:"errorBorderPrimary",textColor:"errorTextPrimary"},successPrimary:{fill:"successPrimary",fillHover:"successHoverPrimary",titleColor:"successTextPrimary",borderColor:"successBorderPrimary",textColor:"successTextPrimary"}},w={appearance:$},F=React__default.forwardRef(function(i,a){const{appearance:o,className:c,dataTestId:S,dataTour:p,initialIsVisible:x,title:z,text:u,before:b,after:g,openTimeoutDelay:C=500,closeTimeoutDelay:v=250,isSkeleton:P,children:T}=i,h=useRef(null),H=useRef(null),A=useRef(null),$=useRef(false),[F,X]=useState(x),I=useCallback(()=>{$.current||(H.current&&clearTimeout(H.current),A.current=setTimeout(()=>{X(true);},C));},[C]),k=useCallback(()=>{A.current&&clearTimeout(A.current),H.current=setTimeout(()=>{X(e=>(true===e&&($.current=true),false));},v);},[v]),N=useCallback(()=>{$.current=false;},[]);useImperativeHandle(a,()=>({get tooltipElement(){return h.current},openTooltip:I,closeTooltip:k,isTooltipVisible:F}),[F,I,k]);const Q=e$1(o,w),L=u$1(i,Q),{alignClass:D,alignDirectionClass:M,alignmentClass:W,alignPosition:V,fillClass:E,titleColor:O,titleSize:j,titleWeight:q,borderColorClass:G,borderTypeClass:R,borderWidthClass:U,textColor:J,textSize:K,textWeight:Y,arrowPosition:Z,elevationClass:ee,shapeClass:re,sizeClass:ie,widthClass:ae}=L,{styles:oe}=c$1(i);return jsxRuntimeExports.jsxs("div",{className:clsx(c,"tooltip",V&&`tooltip_align-position_${V}`,M&&`align_${M}`,D&&`align_${D}`,ee&&`elevation_${ee}`,W&&`alignment_${W}`,ie&&`tooltip_size_${ie}`,P&&"skeleton",ae&&`width_${ae}`),ref:h,"data-testid":S,"data-tour":p,style:oe,onAnimationEnd:N,children:[Z&&jsxRuntimeExports.jsx("div",{className:clsx("tooltip__arrow",Z&&`tooltip__arrow_position_${Z}`,E&&`fill_${E}`),children:" "}),b,jsxRuntimeExports.jsxs("div",{className:clsx("tooltip__inner",U&&`border-width_${U}`,G&&`border-color_${G}`,R&&`border_type_${R}`,E&&`fill_${E}`,re&&`shape_${re}`),children:[z&&jsxRuntimeExports.jsx(B,{className:"tooltip__title text",size:j,textColor:O,textWeight:q,children:z}),u&&jsxRuntimeExports.jsx(_$1,{className:"tooltip__text",size:K,textColor:J,textWeight:Y,children:u}),T]}),g]})}),I$1={disabledPrimary:{fill:"surfacePrimary",borderColor:"surfaceBorderPrimary",badgeAppearance:"surfacePrimary",iconFill:"surfaceItemQuaternary"},size12_12:{fillSize:"12",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size14_12:{fillSize:"14",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size14_14:{fillSize:"14",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size16_12:{fillSize:"16",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size16_14:{fillSize:"16",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size16_16:{fillSize:"16",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"16"},size20_12:{fillSize:"20",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size20_14:{fillSize:"20",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size20_16:{fillSize:"20",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"16"},size20_20:{fillSize:"20",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"20"},size24_12:{fillSize:"24",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size24_14:{fillSize:"24",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size24_16:{fillSize:"24",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"16"},size24_20:{fillSize:"24",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"20"},size24_24:{fillSize:"24",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"24"},size32_12:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size32_14:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size32_16:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"16"},size32_20:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"20"},size32_24:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"24"},size32_32:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"32"},size40_12:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size40_14:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size40_16:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"16"},size40_20:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"20"},size40_24:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"24"},size40_32:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"32"},size40_40:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"40"},solid:{borderColor:"none"},outlined:{fill:"none"},full:{},ghost:{fill:"none",borderColor:"none"},accentPrimary:{fill:"accentPrimary",fillHover:"accentHoverPrimary",borderColor:"accentBorderPrimary",badgeAppearance:"surfacePrimary",iconFill:"accentItemPrimary"},accentSecondary:{fill:"accentPrimary",fillHover:"accentHoverPrimary",borderColor:"accentBorderPrimary",iconFill:"accentItemPrimary"},circular:{shape:"circular"},rounded:{shape:"rounded"},roundedXL:{shape:"rounded"},roundedL:{shape:"rounded"},roundedM:{shape:"rounded"},roundedS:{shape:"rounded"},dangerPrimary:{fill:"dangerPrimary",fillHover:"dangerHoverPrimary",borderColor:"dangerBorderSecondary",badgeAppearance:"surfacePrimary",iconFill:"dangerItemPrimary"},errorPrimary:{fill:"errorPrimary",fillHover:"errorHoverPrimary",borderColor:"errorBorderPrimary",badgeAppearance:"surfacePrimary",iconFill:"errorItemPrimary"},infoPrimary:{fill:"infoPrimary",borderColor:"infoBorderPrimary",badgeAppearance:"surfacePrimary",iconFill:"infoItemPrimary"},infoSecondary:{fill:"accentPrimary",fillHover:"accentHoverPrimary",borderColor:"accentBorderPrimary",iconFill:"infoItemSecondary"},specialPrimary:{fill:"specialPrimary",fillHover:"specialHoverPrimary",borderColor:"specialBorderQuaternary",badgeAppearance:"surfacePrimary",iconFill:"specialItemPrimary"},extraPrimary:{fill:"extraPrimary",fillHover:"extraHoverPrimary",borderColor:"extraBorderQuaternary",badgeAppearance:"surfacePrimary",iconFill:"extraItemPrimary"},successPrimary:{fill:"successPrimary",fillHover:"successHoverPrimary",borderColor:"successBorderPrimary",badgeAppearance:"surfacePrimary",iconFill:"successItemPrimary"},surfacePrimary:{fill:"surfacePrimary",fillHover:"surfaceHoverSecondary",borderColor:"surfaceBorderTertiary",badgeAppearance:"surfacePrimary",iconFill:"surfaceItemPrimary"},surfaceQuaternary:{fill:"surfaceQuaternary",fillHover:"surfaceHoverQuaternary",badgeAppearance:"accentPrimary",iconFill:"surfaceItemPrimary"},surfaceSecondary:{fill:"surfaceSecondary",fillHover:"surfaceHoverSecondary",badgeAppearance:"accentPrimary solid rounded",iconFill:"surfaceItemPrimary"},surfaceTertiary:{fill:"surfaceTertiary",fillHover:"surfaceHoverTertiary",badgeAppearance:"accentPrimary",iconFill:"surfaceItemPrimary"},warningPrimary:{fill:"warningPrimary",fillHover:"warningHoverPrimary",borderColor:"warningBorderSecondary",badgeAppearance:"surfacePrimary",iconFill:"warningItemPrimary"}},k={appearance:I$1},N=f$1(React__default.forwardRef(function(i,a){const{id:l,appearance:t,className:s,dataTestId:n,dataTour:c,width:p,height:z,badgeClass:u,href:_,imageSrc:b,link:g,linkRel:v,linkTarget:P,notification:T,saveFillStroke:H,showTooltip:A,SvgImage:B,svgImageStyles:$,before:w,after:X,isActive:I,isDisabled:N,isSkeleton:L,onClick:D,onMouseEnter:M,onMouseLeave:W}=i,V=useMemo$1(()=>{if(B){const e=B,i={};return p&&(i.width=p),z&&(i.height=z),jsxRuntimeExports.jsx(e,{...i,...$})}return b?b.endsWith(".svg")?jsxRuntimeExports.jsx(InlineSVG,H?{src:b}:{src:b,preProcessor:Q}):jsxRuntimeExports.jsx("img",{src:b}):null},[B,b,p,z,$,H]),E=e$1(t,k,N),O=u$1(i,E),{alignmentClass:j,fillActiveClass:q,fillActiveHoverClass:G,fillClass:R,fillDisabledClass:U,fillHoverClass:J,fillSizeClass:K,borderColorClass:Y,borderColorHoverClass:Z,borderTypeClass:ee,borderWidthClass:re,badgeAppearance:ie,badgeAppearanceSize:ae,badgeShape:oe,badgeSize:le,badgeTextColor:te,badgeTextSize:se,badgeValue:ne,centeringClass:ce,iconFillActiveClass:de,iconFillActiveHoverClass:fe,iconFillClass:ye,iconFillDisabledClass:me,iconFillHoverClass:Se,iconSizeClass:pe,shapeClass:xe,tooltipAppearance:ze,tooltipText:ue,tooltipTextSize:_e,tooltipTitle:be,tooltipTitleSize:ge}=O,{styles:Ce}=c$1(i);return jsxRuntimeExports.jsxs("div",{id:l,className:clsx(s,"icon",I?q&&`fill_active_${q}`:R&&`fill_${R}`,I?G&&`fill_active_hover_${G}`:J&&`fill_hover_${J}`,K&&`icon_fill_size_${K}`,U&&`fill_disabled_${U}`,I?de&&`icon_fill_active_${de}`:ye&&`icon_fill_${ye}`,I?fe&&`icon_fill_active_hover_${fe}`:Se&&`icon_fill_hover_${Se}`,N&&me&&`icon_fill_disabled_${me}`,xe&&`shape_${xe}`,Y&&`border-color_${Y}`,Z&&`border-color_hover_${Z}`,re&&`border-width_${re}`,ee&&`border_type_${ee}`,ne&&"icon_with-badge",ce&&`centering_${ce}`,D&&"cursor_type_pointer",L&&"skeleton"),ref:a,"data-testid":n,"data-tour":c,style:Ce,onClick:D,onMouseEnter:M,onMouseLeave:W,children:[w,jsxRuntimeExports.jsxs(h,{className:clsx((g||_||D)&&"cursor_type_pointer",g||_?"icon__link":"icon__item",pe&&`icon_size_${pe}`),href:g||_,LinkComponent:"div",rel:v,target:P,children:[V,(ne||T)&&jsxRuntimeExports.jsx(C,{appearance:r(ie,ae),className:clsx(u,"icon__badge"),size:le,textColor:te,textSize:se,shape:oe,value:ne}),A&&jsxRuntimeExports.jsx(F,{appearance:ze,className:clsx(s,"icon__tooltip",j&&`alignment_${j}`),title:be,titleSize:ge,text:ue,textSize:_e})]}),X]})})),Q=e=>e.replace(/fill=".*?"/g,'fill=""').replace(/stroke=".*?"/g,'stroke=""');
7908
+ const z={sizeXXL:{size:"xxl"},sizeXL:{size:"xl"},sizeL:{size:"l"},sizeM:{size:"m"},sizeS:{size:"s"},sizeXS:{size:"xs"},sizeXXS:{size:"xxs"}},u={appearance:z};function _$1(r){const{appearance:i,className:a,dataTestId:o,dataTour:l,cursor:t,style:s,tag:n="span",before:c,after:S,isActive:p,isDisabled:x,isSkeleton:z,onClick:_,onDoubleClick:b,children:g}=r,C=e$1(i,u,x),v=u$1(r,C),{textAlignClass:P,textColorActiveClass:T,textColorActiveHoverClass:h,textColorClass:H,textColorDisabledClass:A,textColorHoverClass:B,textFontClass:$,textStyleClass:w,textTruncateClass:F,textWeightClass:X,textWrapClass:I,cursorClass:k,sizeClass:N,widthClass:Q}=v,{styles:L}=c$1(r);return jsxRuntimeExports.jsxs(n,{className:clsx(a,"text",N&&`text_size_${N}`,X&&`text-weight_${X}`,P&&`text-align_${P}`,x&&A&&`text-color_${A}`,!p&&!x&&H&&`text-color_${H}`,!p&&!x&&B&&`text-color_hover_${B}`,p&&!x&&h&&`text-color_active_hover_${h}`,p&&!x&&T&&`text-color_active_${T}`,$&&`text-font_${$}`,w&&`text-style_${w}`,I&&`word-wrap_${I}`,F&&`text-truncate_${F}`,z&&"skeleton",Q&&`width_${Q}`,k&&`cursor_${k}`,_&&(t||"cursor_type_pointer")),"data-testid":o,"data-tour":l,style:Object.assign({},L,s),onClick:_,onDoubleClick:b,children:[c,g,S]})}const b$1={sizeXXL:{size:"xxl",textSize:"xl",iconSize:"24"},sizeXL:{size:"xl",textSize:"l",iconSize:"24"},sizeL:{size:"l",textSize:"l",iconSize:"24"},sizeM:{size:"m",textSize:"m",iconSize:"24"},sizeS:{size:"s",textSize:"s",iconSize:"24"},sizeXS:{size:"xs",textSize:"xxs",iconSize:"24"},sizeXXS:{size:"xxs",textSize:"xxs",iconSize:"24"},circular:{shape:"circular"},rounded:{shape:"rounded"},roundedXL:{shape:"rounded"},roundedL:{shape:"rounded"},roundedM:{shape:"rounded"},roundedS:{shape:"rounded"},solid:{borderColor:"none"},outlined:{fill:"none"},full:{},ghost:{fill:"none",borderColor:"none"},accentPrimary:{fill:"accentPrimary",borderColor:"accentBorderQuaternary",textColor:"accentTextPrimary",dotFill:"accentItemPrimary",iconFill:"accentItemPrimary"},accentQuaternary:{fill:"accentQuaternary",borderColor:"accentBorderQuaternary",textColor:"accentTextPrimary",dotFill:"accentItemPrimary",iconFill:"accentItemPrimary"},accentSecondary:{fill:"accentSecondary",borderColor:"accentBorderQuaternary",textColor:"accentTextQuaternary",dotFill:"accentItemQuaternary",iconFill:"accentItemQuaternary"},accentTertiary:{fill:"accentTertiary",borderColor:"accentBorderSecondary",textColor:"accentTextSecondary",dotFill:"accentItemSecondary",iconFill:"accentItemSecondary"},dangerPrimary:{fill:"dangerPrimary",borderColor:"dangerBorderPrimary",textColor:"dangerTextPrimary",dotFill:"dangerItemPrimary",iconFill:"dangerItemPrimary"},errorPrimary:{fill:"errorPrimary",fillHover:"errorHoverPrimary",textColor:"errorTextPrimary",iconFill:"errorItemPrimary"},infoPrimary:{fill:"infoPrimary",borderColor:"infoBorderSecondary",textColor:"infoTextPrimary",dotFill:"infoItemPrimary",iconFill:"infoItemPrimary"},infoSecondary:{fill:"infoSecondary",borderColor:"infoBorderSecondary",textColor:"infoTextSecondary",dotFill:"infoItemSecondary"},specialPrimary:{fill:"specialPrimary",borderColor:"specialBorderSecondary",textColor:"specialTextPrimary",dotFill:"specialItemPrimary",iconFill:"specialItemPrimary"},extraPrimary:{fill:"extraPrimary",borderColor:"extraBorderSecondary",textColor:"extraTextPrimary",dotFill:"extraItemPrimary",iconFill:"extraItemPrimary"},successPrimary:{fill:"successPrimary",borderColor:"successBorderPrimary",textColor:"successTextPrimary",dotFill:"successItemPrimary",iconFill:"successItemPrimary"},disabledPrimary:{fill:"surfacePrimary",borderColor:"surfaceBorderPrimary",textColor:"surfaceTextPrimary",iconFill:"surfaceItemPrimary"},surfacePrimary:{fill:"surfacePrimary",borderColor:"surfaceBorderTertiary",textColor:"surfaceTextPrimary",dotFill:"surfaceItemPrimary",iconFill:"surfaceItemPrimary"},surfaceQuaternary:{fill:"accentPrimary",borderColor:"surfaceBorderPrimary",textColor:"surfaceTextPrimary"},surfaceSecondary:{fill:"surfaceSecondary",borderColor:"surfaceBorderSecondary",textColor:"surfaceTextPrimary"},surfaceTertiary:{fill:"surfaceTertiary",borderColor:"surfaceBorderTertiary",textColor:"surfaceTextPrimary"},warningPrimary:{fill:"warningPrimary",borderColor:"warningBorderPrimary",textColor:"warningTextPrimary",dotFill:"warningItemPrimary",iconFill:"warningItemPrimary"}},g={appearance:b$1};function C(i){const{appearance:a,className:o,dataTestId:l,dataTour:t,dot:s,icon:n,iconSrc:c,value:S,isSkeleton:p,children:x}=i,z=e$1(a,g),u=u$1(i,z),{fillClass:b,fillHoverClass:C,borderColorClass:v,borderColorHoverClass:P,borderTypeClass:T,borderWidthClass:h,textColor:H,textSize:A,dotFillClass:B,iconFill:$,iconShape:w,iconSize:F,shapeClass:X,sizeClass:I}=u,{styles:k}=c$1(i);return jsxRuntimeExports.jsxs("div",{className:clsx(o,"badge",v&&`border-color_${v}`,P&&`border-color_hover_${P}`,h&&`border-width_${h}`,T&&`border_type_${T}`,b&&`fill_${b}`,C&&`fill_hover_${C}`,I&&`badge_size_${I}`,X&&`shape_${X}`,S?n?s?"badge_type_dot-icon-counter":"badge_type_icon-counter":"badge_type_counter":n?"badge_type_icon":s?"badge_type_dot":"badge_type_fill",p&&"skeleton"),"data-testid":l,"data-tour":t,style:k,children:[s&&jsxRuntimeExports.jsx("div",{className:clsx("badge__dot",B&&`svg_fill_${B}`),children:jsxRuntimeExports.jsx("svg",{width:"6",height:"6",viewBox:"0 0 6 6",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntimeExports.jsx("rect",{width:"6",height:"6",rx:"50"})})}),n&&jsxRuntimeExports.jsx(N,{className:"badge__icon",size:F,iconFill:$,imageSrc:c,shape:w,SvgImage:n}),x||S&&jsxRuntimeExports.jsx(_$1,{className:"badge__value",size:A,textColor:H,children:S})]})}const P$2={LinkComponent:"a"};function h(e){const{href:i,LinkComponent:o,rel:l,target:t,children:s,...n}=e;if(i){const e=o||P$2.LinkComponent;return jsxRuntimeExports.jsx(e,{href:i,rel:l,target:t,...n,children:s})}else if(o)return jsxRuntimeExports.jsx(o,{...n,children:s});return React__default.Children.toArray(s).filter(Boolean).map(e=>React__default.isValidElement(e)?React__default.cloneElement(e,n):e)}const H={h1:{size:"h1",iconAfterFillSize:"24",iconAfterSize:"24",iconBeforeFillSize:"24",iconBeforeSize:"24"},h2:{size:"h2",iconAfterFillSize:"24",iconAfterSize:"24",iconBeforeFillSize:"24",iconBeforeSize:"24"},h3:{size:"h3",iconAfterFillSize:"24",iconAfterSize:"24",iconBeforeFillSize:"24",iconBeforeSize:"24"},h4:{size:"h4",iconAfterFillSize:"24",iconAfterSize:"24",iconBeforeFillSize:"24",iconBeforeSize:"24"},h5:{size:"h5",iconAfterFillSize:"20",iconAfterSize:"20",iconBeforeFillSize:"20",iconBeforeSize:"20"},h6:{size:"h6",iconAfterFillSize:"16",iconAfterSize:"16",iconBeforeFillSize:"16",iconBeforeSize:"16"},disabledPrimary:{fill:"surfacePrimary",borderColor:"errorBorderQuaternary",borderHover:"errorBorderHoverQuaternary",textColor:"surfaceTextQuaternary",iconBeforeFill:"errorQuaternary"},disabledSecondary:{fill:"surfaceSecondary",borderColor:"surfaceBorderTertiary",borderHover:"surfaceBorderHoverQuaternary",iconBeforeFill:"surfaceQuaternary"},solid:{},outlined:{fill:"none"},full:{},ghost:{fill:"none"},accentPrimary:{fill:"accentPrimary",fillHover:"accentHoverPrimary"},accentSecondary:{fill:"accentPrimary",fillHover:"accentHoverPrimary"},dangerPrimary:{fill:"dangerPrimary",fillHover:"dangerHoverPrimary"},errorPrimary:{fill:"errorPrimary",fillHover:"errorHoverPrimary",textColor:"errorTextPrimary",textColorHover:"errorTextPrimary"},infoPrimary:{fill:"accentPrimary",fillHover:"accentHoverPrimary"},infoSecondary:{fill:"accentPrimary",fillHover:"accentHoverPrimary"},specialPrimary:{fill:"specialPrimary",fillHover:"specialHoverPrimary"},extraPrimary:{fill:"extraPrimary",fillHover:"extraHoverPrimary",textColor:"extraTextPrimary"},successPrimary:{fill:"successPrimary",fillHover:"successHoverPrimary"},surfacePrimary:{fill:"surfacePrimary",fillHover:"surfaceHoverPrimary"},surfaceQuaternary:{fill:"surfaceQuaternary",fillHover:"surfaceHoverQuaternary"},surfaceSecondary:{fill:"surfaceSecondary",fillHover:"surfaceHoverSecondary"},surfaceTertiary:{fill:"surfaceTertiary",fillHover:"surfaceHoverTertiary"},warningPrimary:{fill:"warningPrimary",fillHover:"warningHoverPrimary",textColor:"warningTextSecondary",textColorHover:"warningTextSecondary"},requirePrimary:{fill:"warningTertiary",borderColor:"warningBorderQuaternary",borderHover:"warningBorderQuaternary",textColor:"surfaceTextPrimary",iconBeforeFill:"warningQuaternary"},requireSecondary:{fill:"surfaceSecondary",borderColor:"surfaceBorderTertiary",borderHover:"surfaceBorderQuaternary",iconBeforeFill:"surfaceQuaternary"}},A={appearance:H};function B(i){const{appearance:a,className:l,dataTestId:t,dataTour:s,text:n,afterWrapper:c,beforeWrapper:S,style:p,tag:x="span",before:z,after:u,isActive:_,isDisabled:b,isSkeleton:g,onClick:C,children:v}=i,P=e$1(a,A,b),T=u$1(i,P),{directionClass:h,size:H,fillClass:B,fillHoverClass:$,textAlignClass:w,textColorActiveClass:F,textColorActiveHoverClass:X,textColorClass:I,textColorDisabledClass:k,textColorHoverClass:Q,textFontClass:L,textStyleClass:D,textTruncateClass:M,textWeightClass:W,textWrap:V,heightClass:E,iconAfter:O,iconAfterFill:j,iconAfterFillIcon:q,iconAfterFillSize:G,iconAfterShape:R,iconAfterSize:U,iconAfterSrc:J,iconBadgeAppearance:K,iconBadgeShape:Y,iconBadgeSize:Z,iconBadgeTextColor:ee,iconBadgeTextSize:re,iconBadgeValue:ie,iconBefore:ae,iconBeforeFill:oe,iconBeforeFillIcon:le,iconBeforeFillSize:te,iconBeforeShape:se,iconBeforeSize:ne,iconBeforeSrc:ce,svgFillClass:de,svgFillHoverClass:fe,widthClass:ye,wrapperDirectionClass:me,onClickIconAfter:Se,onClickIconBefore:pe}=T,{styles:xe,wrapper:ze}=c$1(i),ue=useMemo$1(()=>x||(H||"span"),[x,H]);return jsxRuntimeExports.jsxs(ue,{className:clsx(l,"title",B&&`fill_${B}`,$&&`fill_hover_${$}`,de&&`svg_fill_${de}`,fe&&`svg_fill_hover_${fe}`,ye&&`width_${ye}`,E&&`height_${E}`,H&&`title_size_${H}`,h&&`title_direction_${h}`,b&&k&&`text-color_${k}`,!_&&!b&&I&&`text text-color_${I}`,_&&!b&&F&&`text-color_active_${F}`,!_&&!b&&Q&&`text-color_hover_${Q}`,_&&!b&&X&&`text-color_active_hover${X}`,L&&`text-font_${L}`,D&&`text-style_${D}`,W&&`text-weight_${W}`,V&&`word-wrap_${V}`,ie&&"title_badge",g&&"skeleton"),"data-testid":t,"data-tour":s,style:Object.assign({},xe,p),onClick:C,children:[z,jsxRuntimeExports.jsxs("span",{className:clsx(w&&`text-align_${w}`,me&&`title_direction_${me}`,"title__wrapper",M&&`text-truncate_${M}`),style:ze,children:[(ae||ce)&&jsxRuntimeExports.jsx(N,{className:clsx("title__icon_before",ie&&"title__icon_before-badge"),fill:oe,fillSize:te,badgeAppearance:K,badgeClass:"title__icon_before_badge",badgeShape:Y,badgeSize:Z,badgeTextColor:ee,badgeTextSize:re,badgeValue:ie,iconFill:le,iconSize:ne,imageSrc:ce,shape:se,SvgImage:ae,onClick:pe}),S,v||n,c,(O||J)&&jsxRuntimeExports.jsx(N,{className:clsx("title__icon_after",ie&&"title__icon_after-badge"),fill:j,fillSize:G,badgeAppearance:K,badgeClass:"title__icon_after_badge",badgeShape:Y,badgeSize:Z,badgeTextColor:ee,badgeTextSize:re,badgeValue:ie,iconFill:q,iconSize:U,imageSrc:J,shape:R,SvgImage:O,onClick:Se})]}),u]})}const $={defaultPrimary:{fill:"surfacePrimary",fillHover:"surfaceHoverPrimary",titleColor:"surfaceTextPrimary",borderColor:"surfaceBorderPrimary",textColor:"surfaceTextPrimary"},sizeL:{size:"l",titleSize:"h5",textSize:"s"},sizeM:{size:"m",titleSize:"h5",textSize:"s"},sizeS:{size:"s",titleSize:"h5",textSize:"s"},disabledPrimary:{fill:"disabledPrimary",fillHover:"disabledHoverPrimary",titleColor:"surfaceTextPrimary",textColor:"surfaceTextPrimary"},requirePrimary:{fill:"warningPrimary",fillHover:"warningHoverPrimary",titleColor:"warningTextPrimary",borderColor:"warningBorderPrimary",textColor:"warningTextPrimary"},circular:{shape:"circular"},rounded:{shape:"rounded"},roundedXL:{shape:"rounded"},roundedL:{shape:"rounded"},roundedM:{shape:"rounded"},roundedS:{shape:"rounded"},solid:{borderColor:"none"},outlined:{fill:"none"},full:{},ghost:{fill:"none",borderColor:"none"},errorPrimary:{fill:"errorPrimary",fillHover:"errorHoverPrimary",titleColor:"errorTextPrimary",borderColor:"errorBorderPrimary",textColor:"errorTextPrimary"},successPrimary:{fill:"successPrimary",fillHover:"successHoverPrimary",titleColor:"successTextPrimary",borderColor:"successBorderPrimary",textColor:"successTextPrimary"}},w={appearance:$},F=React__default.forwardRef(function(i,a){const{appearance:o,className:c,dataTestId:S,dataTour:p,initialIsVisible:x,title:z,text:u,before:b,after:g,openTimeoutDelay:C=500,closeTimeoutDelay:v=250,isSkeleton:P,children:T}=i,h=useRef(null),H=useRef(null),A=useRef(null),$=useRef(false),[F,X]=useState(x),I=useCallback(()=>{$.current||(H.current&&clearTimeout(H.current),A.current=setTimeout(()=>{X(true);},C));},[C]),k=useCallback(()=>{A.current&&clearTimeout(A.current),H.current=setTimeout(()=>{X(e=>(true===e&&($.current=true),false));},v);},[v]),N=useCallback(()=>{$.current=false;},[]);useImperativeHandle(a,()=>({get tooltipElement(){return h.current},openTooltip:I,closeTooltip:k,isTooltipVisible:F}),[F,I,k]);const Q=e$1(o,w),L=u$1(i,Q),{alignClass:D,alignDirectionClass:M,alignmentClass:W,alignPosition:V,fillClass:E,titleColor:O,titleSize:j,titleWeight:q,borderColorClass:G,borderTypeClass:R,borderWidthClass:U,textColor:J,textSize:K,textWeight:Y,arrowPosition:Z,elevationClass:ee,shapeClass:re,sizeClass:ie,widthClass:ae}=L,{styles:oe}=c$1(i);return jsxRuntimeExports.jsxs("div",{className:clsx(c,"tooltip",V&&`tooltip_align-position_${V}`,M&&`align_${M}`,D&&`align_${D}`,ee&&`elevation_${ee}`,W&&`alignment_${W}`,ie&&`tooltip_size_${ie}`,P&&"skeleton",ae&&`width_${ae}`),ref:h,"data-testid":S,"data-tour":p,style:oe,onAnimationEnd:N,children:[Z&&jsxRuntimeExports.jsx("div",{className:clsx("tooltip__arrow",Z&&`tooltip__arrow_position_${Z}`,E&&`fill_${E}`),children:" "}),b,jsxRuntimeExports.jsxs("div",{className:clsx("tooltip__inner",U&&`border-width_${U}`,G&&`border-color_${G}`,R&&`border_type_${R}`,E&&`fill_${E}`,re&&`shape_${re}`),children:[z&&jsxRuntimeExports.jsx(B,{className:"tooltip__title text",size:j,textColor:O,textWeight:q,children:z}),u&&jsxRuntimeExports.jsx(_$1,{className:"tooltip__text",size:K,textColor:J,textWeight:Y,children:u}),T]}),g]})}),I$1={disabledPrimary:{fill:"surfacePrimary",borderColor:"surfaceBorderPrimary",badgeAppearance:"surfacePrimary",iconFill:"surfaceItemQuaternary"},size12_12:{fillSize:"12",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size14_12:{fillSize:"14",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size14_14:{fillSize:"14",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size16_12:{fillSize:"16",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size16_14:{fillSize:"16",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size16_16:{fillSize:"16",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"16"},size20_12:{fillSize:"20",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size20_14:{fillSize:"20",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size20_16:{fillSize:"20",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"16"},size20_20:{fillSize:"20",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"20"},size24_12:{fillSize:"24",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size24_14:{fillSize:"24",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size24_16:{fillSize:"24",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"16"},size24_20:{fillSize:"24",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"20"},size24_24:{fillSize:"24",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"24"},size32_12:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size32_14:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size32_16:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"16"},size32_20:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"20"},size32_24:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"24"},size32_32:{fillSize:"32",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"32"},size40_12:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"12"},size40_14:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"14"},size40_16:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"16"},size40_20:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"20"},size40_24:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"24"},size40_32:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"32"},size40_40:{fillSize:"40",badgeAppearanceSize:"sizeXXS",badgeSize:"xxs",iconSize:"40"},solid:{borderColor:"none"},outlined:{fill:"none"},full:{},ghost:{fill:"none",borderColor:"none"},accentPrimary:{fill:"accentPrimary",fillHover:"accentHoverPrimary",borderColor:"accentBorderPrimary",badgeAppearance:"surfacePrimary",iconFill:"accentItemPrimary"},accentSecondary:{fill:"accentPrimary",fillHover:"accentHoverPrimary",borderColor:"accentBorderPrimary",iconFill:"accentItemPrimary"},circular:{shape:"circular"},rounded:{shape:"rounded"},roundedXL:{shape:"rounded"},roundedL:{shape:"rounded"},roundedM:{shape:"rounded"},roundedS:{shape:"rounded"},dangerPrimary:{fill:"dangerPrimary",fillHover:"dangerHoverPrimary",borderColor:"dangerBorderSecondary",badgeAppearance:"surfacePrimary",iconFill:"dangerItemPrimary"},errorPrimary:{fill:"errorPrimary",fillHover:"errorHoverPrimary",borderColor:"errorBorderPrimary",badgeAppearance:"surfacePrimary",iconFill:"errorItemPrimary"},infoPrimary:{fill:"infoPrimary",borderColor:"infoBorderPrimary",badgeAppearance:"surfacePrimary",iconFill:"infoItemPrimary"},infoSecondary:{fill:"accentPrimary",fillHover:"accentHoverPrimary",borderColor:"accentBorderPrimary",iconFill:"infoItemSecondary"},specialPrimary:{fill:"specialPrimary",fillHover:"specialHoverPrimary",borderColor:"specialBorderQuaternary",badgeAppearance:"surfacePrimary",iconFill:"specialItemPrimary"},extraPrimary:{fill:"extraPrimary",fillHover:"extraHoverPrimary",borderColor:"extraBorderQuaternary",badgeAppearance:"surfacePrimary",iconFill:"extraItemPrimary"},successPrimary:{fill:"successPrimary",fillHover:"successHoverPrimary",borderColor:"successBorderPrimary",badgeAppearance:"surfacePrimary",iconFill:"successItemPrimary"},surfacePrimary:{fill:"surfacePrimary",fillHover:"surfaceHoverSecondary",borderColor:"surfaceBorderTertiary",badgeAppearance:"surfacePrimary",iconFill:"surfaceItemPrimary"},surfaceQuaternary:{fill:"surfaceQuaternary",fillHover:"surfaceHoverQuaternary",badgeAppearance:"accentPrimary",iconFill:"surfaceItemPrimary"},surfaceSecondary:{fill:"surfaceSecondary",fillHover:"surfaceHoverTertiary",badgeAppearance:"accentPrimary solid rounded",iconFill:"surfaceItemPrimary"},surfaceTertiary:{fill:"surfaceTertiary",fillHover:"surfaceHoverTertiary",badgeAppearance:"accentPrimary",iconFill:"surfaceItemPrimary"},warningPrimary:{fill:"warningPrimary",fillHover:"warningHoverPrimary",borderColor:"warningBorderSecondary",badgeAppearance:"surfacePrimary",iconFill:"warningItemPrimary"}},k={appearance:I$1},N=f$1(React__default.forwardRef(function(i,a){const{id:l,appearance:t,className:s,dataTestId:n,dataTour:c,width:p,height:z,badgeClass:u,href:_,imageSrc:b,link:g,linkRel:v,linkTarget:P,notification:T,saveFillStroke:H,showTooltip:A,SvgImage:B,svgImageStyles:$,before:w,after:X,isActive:I,isDisabled:N,isSkeleton:L,onClick:D,onMouseEnter:M,onMouseLeave:W}=i,V=useMemo$1(()=>{if(B){const e=B,i={};return p&&(i.width=p),z&&(i.height=z),jsxRuntimeExports.jsx(e,{...i,...$})}return b?b.endsWith(".svg")?jsxRuntimeExports.jsx(InlineSVG,H?{src:b}:{src:b,preProcessor:Q}):jsxRuntimeExports.jsx("img",{src:b}):null},[B,b,p,z,$,H]),E=e$1(t,k,N),O=u$1(i,E),{alignmentClass:j,fillActiveClass:q,fillActiveHoverClass:G,fillClass:R,fillDisabledClass:U,fillHoverClass:J,fillSizeClass:K,borderColorClass:Y,borderColorHoverClass:Z,borderTypeClass:ee,borderWidthClass:re,badgeAppearance:ie,badgeAppearanceSize:ae,badgeShape:oe,badgeSize:le,badgeTextColor:te,badgeTextSize:se,badgeValue:ne,centeringClass:ce,iconFillActiveClass:de,iconFillActiveHoverClass:fe,iconFillClass:ye,iconFillDisabledClass:me,iconFillHoverClass:Se,iconSizeClass:pe,shapeClass:xe,tooltipAppearance:ze,tooltipText:ue,tooltipTextSize:_e,tooltipTitle:be,tooltipTitleSize:ge}=O,{styles:Ce}=c$1(i);return jsxRuntimeExports.jsxs("div",{id:l,className:clsx(s,"icon",I?q&&`fill_active_${q}`:R&&`fill_${R}`,I?G&&`fill_active_hover_${G}`:J&&`fill_hover_${J}`,K&&`icon_fill_size_${K}`,U&&`fill_disabled_${U}`,I?de&&`icon_fill_active_${de}`:ye&&`icon_fill_${ye}`,I?fe&&`icon_fill_active_hover_${fe}`:Se&&`icon_fill_hover_${Se}`,N&&me&&`icon_fill_disabled_${me}`,xe&&`shape_${xe}`,Y&&`border-color_${Y}`,Z&&`border-color_hover_${Z}`,re&&`border-width_${re}`,ee&&`border_type_${ee}`,ne&&"icon_with-badge",ce&&`centering_${ce}`,D&&"cursor_type_pointer",L&&"skeleton"),ref:a,"data-testid":n,"data-tour":c,style:Ce,onClick:D,onMouseEnter:M,onMouseLeave:W,children:[w,jsxRuntimeExports.jsxs(h,{className:clsx((g||_||D)&&"cursor_type_pointer",g||_?"icon__link":"icon__item",pe&&`icon_size_${pe}`),href:g||_,LinkComponent:"div",rel:v,target:P,children:[V,(ne||T)&&jsxRuntimeExports.jsx(C,{appearance:r(ie,ae),className:clsx(u,"icon__badge"),size:le,textColor:te,textSize:se,shape:oe,value:ne}),A&&jsxRuntimeExports.jsx(F,{appearance:ze,className:clsx(s,"icon__tooltip",j&&`alignment_${j}`),title:be,titleSize:ge,text:ue,textSize:_e})]}),X]})})),Q=e=>e.replace(/fill=".*?"/g,'fill=""').replace(/stroke=".*?"/g,'stroke=""');
7867
7909
 
7868
7910
  const t={accentPrimary:{fill:"accentPrimary",borderColor:"surfaceBorderSecondary",itemFill:"accentItemPrimary"},accentTertiary:{fill:"accentTertiary",borderColor:"surfaceBorderSecondary",itemFill:"accentItemSecondary"},specialPrimary:{fill:"specialPrimary",borderColor:"surfaceBorderSecondary",itemFill:"specialItemPrimary"},sizeL:{size:"l",textSize:"m"},sizeM:{size:"m",textSize:"s"},sizeS:{size:"s",textSize:"xs"},extraPrimary:{fill:"extraPrimary",borderColor:"surfaceBorderSecondary",itemFill:"extraItemPrimary"},surfacePrimary:{fill:"surfacePrimary",borderColor:"surfaceBorderPrimary",itemFill:"surfaceItemPrimary"},surfaceSecondary:{fill:"surfaceSecondary",borderColor:"surfaceBorderPrimary",itemFill:"surfaceItemPrimary"},surfaceTertiary:{fill:"surfaceTertiary",borderColor:"surfaceBorderPrimary",itemFill:"surfaceItemPrimary"},warningPrimary:{fill:"warningPrimary",borderColor:"surfaceBorderSecondary",itemFill:"warningItemPrimary"},successPrimary:{fill:"successPrimary",borderColor:"surfaceBorderSecondary",itemFill:"successItemPrimary"},infoPrimary:{fill:"infoPrimary",borderColor:"surfaceBorderSecondary",itemFill:"infoItemPrimary"},dangerPrimary:{fill:"dangerPrimary",borderColor:"surfaceBorderSecondary",itemFill:"dangerItemPrimary"},errorPrimary:{fill:"errorPrimary",borderColor:"surfaceBorderSecondary",itemFill:"errorItemPrimary"},solid:{borderColor:"none"},outlined:{fill:"none"},full:{},ghost:{fill:"none",borderColor:"none"}},c={appearance:t};function m(t){const{appearance:m,className:d,dataTestId:n,dataTour:y,type:f="dot",text:u,isDisabled:P,isSkeleton:p,children:C}=t,_=e$1(m,c,P),S=u$1(t,_),{fillClass:b,borderColorClass:h,textColor:x,textSize:z,heightClass:F,itemFillClass:I,shapeClass:B,sizeClass:$,widthClass:g}=S,{styles:N}=c$1(t);return jsxRuntimeExports.jsxs("div",{className:clsx("loader",d,g&&`width_${g}`,F&&`height_${F}`,b&&`fill_${b}`,$&&`loader_size_${$}`,p&&"skeleton",f&&`loader_type_${f}`,B&&`shape_${B}`),"data-testid":n,"data-tour":y,style:N,children:[C||jsxRuntimeExports.jsxs("div",{className:"loader__inner",children:[jsxRuntimeExports.jsx("span",{className:clsx("loader__item",I&&`fill_${I}`,"circular"===f&&`border-color_${h}`),children:" "}),jsxRuntimeExports.jsx("span",{className:clsx("loader__item",I&&`fill_${I}`),children:" "}),jsxRuntimeExports.jsx("span",{className:clsx("loader__item",I&&`fill_${I}`),children:" "})]}),u&&jsxRuntimeExports.jsx(_$1,{className:"loader__text",size:z,textColor:x,children:u})]})}
7869
7911
 
7870
- const I="holding",P$1="idle";const T={sizeXXL:{size:"xxl",labelTextSize:"xl",iconAfterAppearanceSize:"size24_24",iconBeforeAppearanceSize:"size24_24",loaderAppearanceSize:"sizeL"},sizeXL:{size:"xl",labelTextSize:"l",iconAfterAppearanceSize:"size24_24",iconBeforeAppearanceSize:"size24_24",loaderAppearanceSize:"sizeL"},sizeL:{size:"l",labelTextSize:"l",iconAfterAppearanceSize:"size24_24",iconBeforeAppearanceSize:"size24_24",loaderAppearanceSize:"sizeL"},sizeM:{size:"m",labelTextSize:"m",iconAfterAppearanceSize:"size24_24",iconBeforeAppearanceSize:"size24_24",loaderAppearanceSize:"sizeL"},sizeS:{size:"s",labelTextSize:"s",iconAfterAppearanceSize:"size20_20",iconBeforeAppearanceSize:"size20_20",loaderAppearanceSize:"sizeL"},sizeXS:{size:"xs",labelTextSize:"xs",iconAfterAppearanceSize:"size16_16",iconBeforeAppearanceSize:"size16_16",loaderAppearanceSize:"sizeL"},sizeXXS:{size:"xxs",labelTextSize:"xs",iconAfterAppearanceSize:"size14_14",iconBeforeAppearanceSize:"size14_14",loaderAppearanceSize:"sizeL"},circular:{shape:"circular"},rounded:{shape:"rounded"},roundedXL:{shape:"rounded"},roundedL:{shape:"rounded"},roundedM:{shape:"rounded"},roundedS:{shape:"rounded"},solid:{borderColor:"none"},outlined:{fill:"none"},full:{},ghost:{fill:"none",borderColor:"none"},accentMutedPrimary:{fill:"accentTertiary",fillHover:"accentHoverTertiary",labelTextColor:"accentTextQuaternary",labelTextColorHover:"accentTextQuaternary",borderColor:"accentBorderSecondary",iconAfterFillIcon:"accentItemQuaternary",iconBeforeFillIcon:"accentItemQuaternary",iconFillIcon:"accentItemQuaternary",loaderAppearance:"accentTertiary"},accentPrimary:{fill:"accentPrimary",fillHover:"accentHoverPrimary",labelTextColor:"accentTextPrimary",labelTextColorHover:"accentTextPrimary",borderColor:"accentBorderPrimary",iconAfterFillIcon:"accentItemPrimary",iconBeforeFillIcon:"accentItemPrimary",iconFillIcon:"accentItemPrimary",loaderAppearance:"accentPrimary"},accentSecondary:{fill:"accentPrimary",fillHover:"accentHoverPrimary",labelTextColor:"accentTextSecondary",labelTextColorHover:"accentTextSecondary",borderColor:"accentBorderPrimary",iconAfterFillIcon:"accentItemPrimary",iconBeforeFillIcon:"accentItemPrimary",iconFillIcon:"accentItemPrimary",loaderAppearance:"accentPrimary"},dangerMutedPrimary:{fill:"dangerTertiary",fillHover:"dangerHoverPrimary",labelTextColor:"dangerTextQuaternary",labelTextColorHover:"dangerTextQuaternary",borderColor:"dangerBorderSecondary",iconAfterFillIcon:"dangerItemQuaternary",iconBeforeFillIcon:"dangerItemQuaternary",iconFillIcon:"dangerItemQuaternary",loaderAppearance:"dangerTertiary"},dangerPrimary:{fill:"dangerPrimary",fillHover:"dangerHoverPrimary",labelTextColor:"dangerTextPrimary",labelTextColorHover:"dangerTextPrimary",iconAfterFillIcon:"dangerItemPrimary",iconBeforeFillIcon:"dangerItemPrimary",iconFillIcon:"dangerItemPrimary",loaderAppearance:"dangerPrimary"},errorMutedPrimary:{fill:"errorTertiary",fillHover:"errorHoverPrimary",labelTextColor:"errorTextQuaternary",labelTextColorHover:"errorTextQuaternary",borderColor:"errorBorderSecondary",iconAfterFillIcon:"errorItemQuaternary",iconBeforeFillIcon:"errorItemQuaternary",iconFillIcon:"errorItemQuaternary",loaderAppearance:"errorTertiary"},errorPrimary:{fill:"errorPrimary",fillHover:"errorHoverPrimary",labelTextColor:"errorTextPrimary",labelTextColorHover:"errorTextPrimary",iconAfterFillIcon:"errorItemPrimary",iconBeforeFillIcon:"errorItemPrimary",iconFillIcon:"errorItemPrimary",loaderAppearance:"errorPrimary"},infoMutedPrimary:{fill:"infoTertiary",fillHover:"infoHoverTertiary",labelTextColor:"infoTextSecondary",labelTextColorHover:"infoTextSecondary",borderColor:"infoBorderSecondary",iconAfterFillIcon:"infoItemSecondary",iconBeforeFillIcon:"infoItemSecondary",iconFillIcon:"infoItemSecondary",loaderAppearance:"infoTertiary"},infoPrimary:{fill:"infoPrimary",fillHover:"infoHoverPrimary",labelTextColor:"infoTextPrimary",labelTextColorHover:"infoTextPrimary",borderColor:"infoBorderPrimary",iconAfterFillIcon:"infoItemPrimary",iconBeforeFillIcon:"infoItemPrimary",iconFillIcon:"infoItemPrimary",loaderAppearance:"infoPrimary"},infoSecondary:{fill:"infoPrimary",fillHover:"infoHoverPrimary",labelTextColor:"infoTextSecondary",labelTextColorHover:"infoTextSecondary",borderColor:"infoBorderPrimary",iconAfterFillIcon:"infoItemPrimary",iconBeforeFillIcon:"infoItemPrimary",iconFillIcon:"infoItemPrimary",loaderAppearance:"infoPrimary"},specialMutedPrimary:{fill:"specialTertiary",fillHover:"specialHoverPrimary",labelTextColor:"specialTextSecondary",borderColor:"specialBorderTertiary",iconAfterFillIcon:"specialItemSecondary",iconBeforeFillIcon:"specialItemSecondary",iconFillIcon:"specialItemSecondary",loaderAppearance:"specialTertiary"},specialPrimary:{fill:"specialPrimary",fillHover:"specialHoverPrimary",labelTextColor:"specialTextPrimary",iconAfterFillIcon:"specialItemPrimary",iconBeforeFillIcon:"specialItemPrimary",iconFillIcon:"specialItemPrimary",loaderAppearance:"specialPrimary"},extraMutedPrimary:{fill:"extraTertiary",fillHover:"extraHoverPrimary",labelTextColor:"extraTextQuaternary",borderColor:"extraBorderSecondary",iconAfterFillIcon:"extraItemQuaternary",iconBeforeFillIcon:"extraItemQuaternary",iconFillIcon:"extraItemQuaternary",loaderAppearance:"extraPrimary"},extraPrimary:{fill:"extraPrimary",fillHover:"extraHoverPrimary",labelTextColor:"extraTextPrimary",iconAfterFillIcon:"extraItemPrimary",iconBeforeFillIcon:"extraItemPrimary",iconFillIcon:"extraItemPrimary",loaderAppearance:"extraPrimary"},successMutedPrimary:{fill:"successTertiary",fillHover:"successHoverPrimary",labelTextColor:"successTextQuaternary",labelTextColorHover:"successTextQuaternary",borderColor:"successBorderQuaternary",iconAfterFillIcon:"successItemQuaternary",iconBeforeFillIcon:"successItemQuaternary",iconFillIcon:"successItemQuaternary",loaderAppearance:"successTertiary"},successPrimary:{fill:"successPrimary",fillHover:"successHoverPrimary",labelTextColor:"successTextPrimary",labelTextColorHover:"successTextPrimary",iconAfterFillIcon:"successItemPrimary",iconBeforeFillIcon:"successItemPrimary",iconFillIcon:"successItemPrimary",loaderAppearance:"successPrimary"},surfaceMutedPrimary:{fill:"surfaceTertiary",fillHover:"surfaceTertiary",labelTextColor:"surfaceTextQuaternary",borderColor:"surfaceBorderQuaternary",iconAfterFillIcon:"surfaceItemQuaternary",iconBeforeFillIcon:"surfaceItemQuaternary",iconFillIcon:"surfaceItemQuaternary",loaderAppearance:"surfaceTertiary"},surfacePrimary:{fill:"surfacePrimary",fillHover:"surfaceSecondary",labelTextColor:"surfaceTextPrimary",borderColor:"surfaceBorderTertiary",iconAfterFillIcon:"surfaceItemPrimary",iconBeforeFillIcon:"surfaceItemPrimary",iconFillIcon:"surfaceItemPrimary",loaderAppearance:"surfacePrimary"},surfaceQuaternary:{fill:"surfaceTertiary",fillHover:"surfaceTertiary",labelTextColor:"surfaceTextPrimary",borderColor:"surfaceBorderTertiary",iconAfterFillIcon:"surfaceItemPrimary",iconBeforeFillIcon:"surfaceItemPrimary",iconFillIcon:"surfaceItemPrimary",loaderAppearance:"surfacePrimary"},surfaceSecondary:{fill:"surfaceSecondary",fillHover:"surfaceTertiary",labelTextColor:"surfaceTextPrimary",borderColor:"surfaceBorderTertiary",iconAfterFillIcon:"surfaceItemPrimary",iconBeforeFillIcon:"surfaceItemPrimary",iconFillIcon:"surfaceItemPrimary",loaderAppearance:"surfacePrimary"},surfaceTertiary:{fill:"surfaceTertiary",fillHover:"surfaceSecondary",labelTextColor:"surfaceTextPrimary",iconAfterFillIcon:"surfaceItemPrimary",iconBeforeFillIcon:"surfaceItemPrimary",iconFillIcon:"surfaceItemPrimary",loaderAppearance:"surfacePrimary"},warningMutedPrimary:{fill:"warningTertiary",fillHover:"warningHoverPrimary",labelTextColor:"warningTextSecondary",labelTextColorHover:"warningTextPrimary",borderColor:"warningBorderPrimary",iconAfterFillIcon:"warningItemSecondary",iconBeforeFillIcon:"warningItemSecondary",iconFillIcon:"warningItemSecondary",loaderAppearance:"warningTertiary"},warningPrimary:{fill:"warningPrimary",fillHover:"warningHoverPrimary",labelTextColor:"warningTextPrimary",labelTextColorHover:"warningTextPrimary",iconAfterFillIcon:"warningItemPrimary",iconBeforeFillIcon:"warningItemPrimary",iconFillIcon:"warningItemPrimary",loaderAppearance:"warningPrimary"}},x$1={appearance:T},b=React__default.forwardRef(function(a,T){const{appearance:b,className:A,dataTestId:S,dataTour:F,label:z,Badge:C,href:_,htmlType:v="button",link:H,rel:g,target:B,tooltip:h$1,before:Q,after:w,isDisabled:L,isHolding:M,isLoading:$=false,onClick:N$1,onHoldComplete:k,onMouseDown:X,children:D}=a,W=e$1(b,x$1,L),j=u$1(a,W),{fillClass:q,fillHoverClass:E,labelTextColor:G,labelTextColorHover:R,labelTextSize:U,labelTextTruncate:J,labelTextWeight:K,labelTextWidth:O,labelTextWrap:V,borderColorClass:Y,borderTypeClass:Z,borderWidthClass:ee,elevationClass:re,icon:ae,iconAfter:oe,iconAfterAppearance:ie,iconAfterAppearanceSize:le,iconAfterFill:ne,iconAfterFillIcon:te,iconAfterFillSize:ce,iconAfterShape:se,iconAfterSize:me,iconAfterSrc:fe,iconAppearance:ye,iconAppearanceSize:de,iconBefore:pe,iconBeforeAppearance:ue,iconBeforeAppearanceSize:Ie,iconBeforeFill:Pe,iconBeforeFillIcon:Te,iconBeforeFillSize:xe,iconBeforeShape:be,iconBeforeSize:Ae,iconBeforeSrc:Se,iconFill:Fe,iconFillIcon:ze,iconFillSize:Ce,iconShape:_e,iconSize:ve,iconSrc:He,loaderAppearance:ge,loaderAppearanceSize:Be,loaderFill:he,loaderItemFill:Qe,loaderSize:we,loaderType:Le="dot",shapeClass:Me,sizeClass:$e,widthClass:Ne,zeroGap:ke,zeroPadding:Xe,isSkeleton:De}=j,{label:We,styles:je}=c$1(a),{holdState:qe,onHoldEnd:Ee,onHoldStart:Ge}=function(e){const{holdDurationMs:r=500,isHolding:a,onHoldComplete:t}=e,c=useRef(null),s=useRef(t),[m,f]=useState(P$1),y=useRef(0);s.current=t,useEffect(()=>(c.current=requestAnimationFrame(function e(){if(m===I&&1===y.current&&s.current&&s.current(),m===I&&y.current<1){const a=y.current,o=Math.min(a+16/r,1);y.current=o,c.current=requestAnimationFrame(e);}if(m===P$1&&y.current>0){const a=y.current,o=Math.max(a-16/r,0);y.current=o,c.current=requestAnimationFrame(e);}}),()=>{c.current&&cancelAnimationFrame(c.current);}),[m,r]);const d=useCallback(e=>{a&&("touch"!==e.pointerType&&0!==e.button||f(I));},[a]),p=useCallback(e=>{f(P$1);},[]);return {holdState:m,onHoldEnd:p,onHoldStart:d}}({holdDurationMs:500,isHolding:M,onHoldComplete:k}),Re=w||Q||ae||oe||fe||pe||Se||He;return jsxRuntimeExports.jsx(h,{className:clsx(A,"button",z&&Re?"button_type_default":z?"button_type_label":Re?"button_type_icon":"",ee&&`border-width_${ee}`,Y&&`border-color_${Y}`,Z&&`border_type_${Z}`,q&&`fill_${q}`,E&&!L&&`fill_hover_${E}`,Me&&`shape_${Me}`,$e&&`button_size_${$e}`,Ne&&`button_width_${Ne}`,re&&`elevation_${re}`,N$1&&"cursor_type_pointer",L&&"button_state_disabled cursor_type_default",C&&"button_type_badge",Xe&&"button_reset-padding",ke&&"button_reset-gap",$&&"button_state_loading",De&&"skeleton",M&&"button_holding",qe&&`button_state_${qe}`),type:v,title:h$1,"data-testid":S&&`${S}-button`,"data-tour":F,disabled:L,href:H||_,LinkComponent:"button",rel:g,style:je,target:B,onClick:N$1,onMouseDown:X,onPointerCancel:Ee,onPointerDown:Ge,onPointerLeave:Ee,onPointerUp:Ee,children:jsxRuntimeExports.jsxs("div",{className:"button__wrapper",ref:T,children:[M&&jsxRuntimeExports.jsx("div",{className:clsx("button__indication",`button__indication_${qe}`),children:jsxRuntimeExports.jsx("div",{className:"button__indication-item",children:" "})}),$&&jsxRuntimeExports.jsx(m,{appearance:r(ge,Be),className:clsx(A,"button__loader"),type:Le,size:we,fill:he,itemFill:Qe}),Q,(pe||Se)&&jsxRuntimeExports.jsx(N,{appearance:r(ue,Ie),className:"button__icon_before",fill:Pe,fillSize:xe,iconFill:Te,iconSize:Ae,imageSrc:Se,shape:be,SvgImage:pe}),(ae||He)&&jsxRuntimeExports.jsx(N,{appearance:r(ye,de),className:"button__icon",fill:Fe,fillSize:Ce,iconFill:ze,iconSize:ve,imageSrc:He,shape:_e,SvgImage:ae}),(D||z)&&jsxRuntimeExports.jsx(_$1,{className:"button__label",width:O,size:U,textColor:G,textColorHover:R,textTruncate:J,textWeight:K,textWrap:V,style:We,children:D||z}),(oe||fe)&&jsxRuntimeExports.jsx(N,{appearance:r(ie,le),className:"button__icon_after",fill:ne,fillSize:ce,iconFill:te,iconSize:me,imageSrc:fe,shape:se,SvgImage:oe}),C,w]})})});
7912
+ const I="holding",P$1="idle";const T={sizeXXL:{size:"xxl",labelTextSize:"xl",iconAfterAppearanceSize:"size24_24",iconBeforeAppearanceSize:"size24_24",loaderAppearanceSize:"sizeL"},sizeXL:{size:"xl",labelTextSize:"l",iconAfterAppearanceSize:"size24_24",iconBeforeAppearanceSize:"size24_24",loaderAppearanceSize:"sizeL"},sizeL:{size:"l",labelTextSize:"l",iconAfterAppearanceSize:"size24_24",iconBeforeAppearanceSize:"size24_24",loaderAppearanceSize:"sizeL"},sizeM:{size:"m",labelTextSize:"m",iconAfterAppearanceSize:"size24_24",iconBeforeAppearanceSize:"size24_24",loaderAppearanceSize:"sizeL"},sizeS:{size:"s",labelTextSize:"s",iconAfterAppearanceSize:"size20_20",iconBeforeAppearanceSize:"size20_20",loaderAppearanceSize:"sizeL"},sizeXS:{size:"xs",labelTextSize:"xs",iconAfterAppearanceSize:"size16_16",iconBeforeAppearanceSize:"size16_16",loaderAppearanceSize:"sizeL"},sizeXXS:{size:"xxs",labelTextSize:"xs",iconAfterAppearanceSize:"size14_14",iconBeforeAppearanceSize:"size14_14",loaderAppearanceSize:"sizeL"},circular:{shape:"circular"},rounded:{shape:"rounded"},roundedXL:{shape:"rounded"},roundedL:{shape:"rounded"},roundedM:{shape:"rounded"},roundedS:{shape:"rounded"},solid:{borderColor:"none"},outlined:{fill:"none"},full:{},ghost:{fill:"none",borderColor:"none"},accentMutedPrimary:{fill:"accentTertiary",fillHover:"accentHoverTertiary",labelTextColor:"accentTextQuaternary",labelTextColorHover:"accentTextQuaternary",borderColor:"accentBorderSecondary",iconAfterFillIcon:"accentItemQuaternary",iconBeforeFillIcon:"accentItemQuaternary",iconFillIcon:"accentItemQuaternary",loaderAppearance:"accentTertiary"},accentPrimary:{fill:"accentPrimary",fillHover:"accentHoverPrimary",labelTextColor:"accentTextPrimary",labelTextColorHover:"accentTextPrimary",borderColor:"accentBorderPrimary",iconAfterFillIcon:"accentItemPrimary",iconBeforeFillIcon:"accentItemPrimary",iconFillIcon:"accentItemPrimary",loaderAppearance:"accentPrimary"},accentSecondary:{fill:"accentPrimary",fillHover:"accentHoverPrimary",labelTextColor:"accentTextSecondary",labelTextColorHover:"accentTextSecondary",borderColor:"accentBorderPrimary",iconAfterFillIcon:"accentItemPrimary",iconBeforeFillIcon:"accentItemPrimary",iconFillIcon:"accentItemPrimary",loaderAppearance:"accentPrimary"},dangerMutedPrimary:{fill:"dangerTertiary",fillHover:"dangerHoverPrimary",labelTextColor:"dangerTextQuaternary",labelTextColorHover:"dangerTextQuaternary",borderColor:"dangerBorderSecondary",iconAfterFillIcon:"dangerItemQuaternary",iconBeforeFillIcon:"dangerItemQuaternary",iconFillIcon:"dangerItemQuaternary",loaderAppearance:"dangerTertiary"},dangerPrimary:{fill:"dangerPrimary",fillHover:"dangerHoverPrimary",labelTextColor:"dangerTextPrimary",labelTextColorHover:"dangerTextPrimary",iconAfterFillIcon:"dangerItemPrimary",iconBeforeFillIcon:"dangerItemPrimary",iconFillIcon:"dangerItemPrimary",loaderAppearance:"dangerPrimary"},errorMutedPrimary:{fill:"errorTertiary",fillHover:"errorHoverPrimary",labelTextColor:"errorTextQuaternary",labelTextColorHover:"errorTextQuaternary",borderColor:"errorBorderSecondary",iconAfterFillIcon:"errorItemQuaternary",iconBeforeFillIcon:"errorItemQuaternary",iconFillIcon:"errorItemQuaternary",loaderAppearance:"errorTertiary"},errorPrimary:{fill:"errorPrimary",fillHover:"errorHoverPrimary",labelTextColor:"errorTextPrimary",labelTextColorHover:"errorTextPrimary",iconAfterFillIcon:"errorItemPrimary",iconBeforeFillIcon:"errorItemPrimary",iconFillIcon:"errorItemPrimary",loaderAppearance:"errorPrimary"},infoMutedPrimary:{fill:"infoTertiary",fillHover:"infoHoverTertiary",labelTextColor:"infoTextSecondary",labelTextColorHover:"infoTextSecondary",borderColor:"infoBorderSecondary",iconAfterFillIcon:"infoItemSecondary",iconBeforeFillIcon:"infoItemSecondary",iconFillIcon:"infoItemSecondary",loaderAppearance:"infoTertiary"},infoPrimary:{fill:"infoPrimary",fillHover:"infoHoverPrimary",labelTextColor:"infoTextPrimary",labelTextColorHover:"infoTextPrimary",borderColor:"infoBorderPrimary",iconAfterFillIcon:"infoItemPrimary",iconBeforeFillIcon:"infoItemPrimary",iconFillIcon:"infoItemPrimary",loaderAppearance:"infoPrimary"},infoSecondary:{fill:"infoPrimary",fillHover:"infoHoverPrimary",labelTextColor:"infoTextSecondary",labelTextColorHover:"infoTextSecondary",borderColor:"infoBorderPrimary",iconAfterFillIcon:"infoItemPrimary",iconBeforeFillIcon:"infoItemPrimary",iconFillIcon:"infoItemPrimary",loaderAppearance:"infoPrimary"},specialMutedPrimary:{fill:"specialTertiary",fillHover:"specialHoverPrimary",labelTextColor:"specialTextSecondary",borderColor:"specialBorderTertiary",iconAfterFillIcon:"specialItemSecondary",iconBeforeFillIcon:"specialItemSecondary",iconFillIcon:"specialItemSecondary",loaderAppearance:"specialTertiary"},specialPrimary:{fill:"specialPrimary",fillHover:"specialHoverPrimary",labelTextColor:"specialTextPrimary",iconAfterFillIcon:"specialItemPrimary",iconBeforeFillIcon:"specialItemPrimary",iconFillIcon:"specialItemPrimary",loaderAppearance:"specialPrimary"},extraMutedPrimary:{fill:"extraTertiary",fillHover:"extraHoverPrimary",labelTextColor:"extraTextQuaternary",borderColor:"extraBorderSecondary",iconAfterFillIcon:"extraItemQuaternary",iconBeforeFillIcon:"extraItemQuaternary",iconFillIcon:"extraItemQuaternary",loaderAppearance:"extraPrimary"},extraPrimary:{fill:"extraPrimary",fillHover:"extraHoverPrimary",labelTextColor:"extraTextPrimary",iconAfterFillIcon:"extraItemPrimary",iconBeforeFillIcon:"extraItemPrimary",iconFillIcon:"extraItemPrimary",loaderAppearance:"extraPrimary"},successMutedPrimary:{fill:"successTertiary",fillHover:"successHoverPrimary",labelTextColor:"successTextQuaternary",labelTextColorHover:"successTextQuaternary",borderColor:"successBorderQuaternary",iconAfterFillIcon:"successItemQuaternary",iconBeforeFillIcon:"successItemQuaternary",iconFillIcon:"successItemQuaternary",loaderAppearance:"successTertiary"},successPrimary:{fill:"successPrimary",fillHover:"successHoverPrimary",labelTextColor:"successTextPrimary",labelTextColorHover:"successTextPrimary",iconAfterFillIcon:"successItemPrimary",iconBeforeFillIcon:"successItemPrimary",iconFillIcon:"successItemPrimary",loaderAppearance:"successPrimary"},surfaceMutedPrimary:{fill:"surfaceTertiary",fillHover:"surfaceTertiary",labelTextColor:"surfaceTextQuaternary",borderColor:"surfaceBorderQuaternary",iconAfterFillIcon:"surfaceItemQuaternary",iconBeforeFillIcon:"surfaceItemQuaternary",iconFillIcon:"surfaceItemQuaternary",loaderAppearance:"surfaceTertiary"},surfacePrimary:{fill:"surfacePrimary",fillHover:"surfaceSecondary",labelTextColor:"surfaceTextPrimary",borderColor:"surfaceBorderTertiary",iconAfterFillIcon:"surfaceItemPrimary",iconBeforeFillIcon:"surfaceItemPrimary",iconFillIcon:"surfaceItemPrimary",loaderAppearance:"surfacePrimary"},surfaceQuaternary:{fill:"surfaceTertiary",fillHover:"surfaceTertiary",labelTextColor:"surfaceTextPrimary",borderColor:"surfaceBorderTertiary",iconAfterFillIcon:"surfaceItemPrimary",iconBeforeFillIcon:"surfaceItemPrimary",iconFillIcon:"surfaceItemPrimary",loaderAppearance:"surfacePrimary"},surfaceSecondary:{fill:"surfaceSecondary",fillHover:"surfaceTertiary",labelTextColor:"surfaceTextPrimary",borderColor:"surfaceBorderTertiary",iconAfterFillIcon:"surfaceItemPrimary",iconBeforeFillIcon:"surfaceItemPrimary",iconFillIcon:"surfaceItemPrimary",loaderAppearance:"surfacePrimary"},surfaceTertiary:{fill:"surfaceTertiary",fillHover:"surfaceSecondary",labelTextColor:"surfaceTextPrimary",iconAfterFillIcon:"surfaceItemPrimary",iconBeforeFillIcon:"surfaceItemPrimary",iconFillIcon:"surfaceItemPrimary",loaderAppearance:"surfacePrimary"},warningMutedPrimary:{fill:"warningTertiary",fillHover:"warningHoverPrimary",labelTextColor:"warningTextSecondary",labelTextColorHover:"warningTextPrimary",borderColor:"warningBorderPrimary",iconAfterFillIcon:"warningItemSecondary",iconBeforeFillIcon:"warningItemSecondary",iconFillIcon:"warningItemSecondary",loaderAppearance:"warningTertiary"},warningPrimary:{fill:"warningPrimary",fillHover:"warningHoverPrimary",labelTextColor:"warningTextPrimary",labelTextColorHover:"warningTextPrimary",iconAfterFillIcon:"warningItemPrimary",iconBeforeFillIcon:"warningItemPrimary",iconFillIcon:"warningItemPrimary",loaderAppearance:"warningPrimary"}},x$1={appearance:T},b=React__default.forwardRef(function(a,T){const{appearance:b,className:A,dataTestId:S,dataTour:F,label:z,Badge:C,href:_,htmlType:v="button",link:H,rel:g,target:B,tooltip:h$1,before:Q,after:w,isDisabled:L,isHolding:M,isLoading:$=false,onClick:N$1,onHoldComplete:k,onMouseDown:X,children:D}=a,W=e$1(b,x$1,L),j=u$1(a,W),{fillClass:q,fillHoverClass:E,labelTextColor:G,labelTextColorHover:R,labelTextSize:U,labelTextTruncate:J,labelTextWeight:K,labelTextWidth:O,labelTextWrap:V,borderColorClass:Y,borderTypeClass:Z,borderWidthClass:ee,elevationClass:re,icon:ae,iconAfter:oe,iconAfterAppearance:ie,iconAfterAppearanceSize:le,iconAfterFill:ne,iconAfterFillIcon:ce,iconAfterFillSize:te,iconAfterShape:se,iconAfterSize:me,iconAfterSrc:fe,iconAppearance:ye,iconAppearanceSize:de,iconBefore:pe,iconBeforeAppearance:ue,iconBeforeAppearanceSize:Ie,iconBeforeFill:Pe,iconBeforeFillIcon:Te,iconBeforeFillSize:xe,iconBeforeShape:be,iconBeforeSize:Ae,iconBeforeSrc:Se,iconFill:Fe,iconFillIcon:ze,iconFillSize:Ce,iconShape:_e,iconSize:ve,iconSrc:He,loaderAppearance:ge,loaderAppearanceSize:Be,loaderFill:he,loaderItemFill:Qe,loaderSize:we,loaderType:Le="dot",shapeClass:Me,sizeClass:$e,widthClass:Ne,zeroGap:ke,zeroPadding:Xe,isSkeleton:De}=j,{label:We,styles:je}=c$1(a),{holdState:qe,onHoldEnd:Ee,onHoldStart:Ge}=function(e){const{holdDurationMs:r=500,isHolding:a,onHoldComplete:c}=e,t=useRef(null),s=useRef(c),[m,f]=useState(P$1),y=useRef(0);s.current=c,useEffect(()=>(t.current=requestAnimationFrame(function e(){if(m===I&&1===y.current&&s.current&&s.current(),m===I&&y.current<1){const a=y.current,o=Math.min(a+16/r,1);y.current=o,t.current=requestAnimationFrame(e);}if(m===P$1&&y.current>0){const a=y.current,o=Math.max(a-16/r,0);y.current=o,t.current=requestAnimationFrame(e);}}),()=>{t.current&&cancelAnimationFrame(t.current);}),[m,r]);const d=useCallback(e=>{a&&("touch"!==e.pointerType&&0!==e.button||f(I));},[a]),p=useCallback(e=>{f(P$1);},[]);return {holdState:m,onHoldEnd:p,onHoldStart:d}}({holdDurationMs:500,isHolding:M,onHoldComplete:k}),Re=w||Q||ae||oe||fe||pe||Se||He;return jsxRuntimeExports.jsx(h,{className:clsx(A,"button",z&&Re?"button_type_default":z?"button_type_label":Re?"button_type_icon":"",ee&&`border-width_${ee}`,Y&&`border-color_${Y}`,Z&&`border_type_${Z}`,q&&`fill_${q}`,E&&!L&&`fill_hover_${E}`,Me&&`shape_${Me}`,$e&&`button_size_${$e}`,Ne&&`button_width_${Ne}`,re&&`elevation_${re}`,N$1&&"cursor_type_pointer",L&&"button_state_disabled cursor_type_default",C&&"button_type_badge",Xe&&"button_reset-padding",ke&&"button_reset-gap",$&&"button_state_loading",De&&"skeleton",M&&"button_holding",qe&&`button_state_${qe}`),type:v,title:h$1,"data-testid":S&&`${S}-button`,"data-tour":F,disabled:L,href:H??_,LinkComponent:H??_?"a":"button",rel:g,style:je,target:B,onClick:N$1,onMouseDown:X,onPointerCancel:Ee,onPointerDown:Ge,onPointerLeave:Ee,onPointerUp:Ee,children:jsxRuntimeExports.jsxs("div",{className:"button__wrapper",ref:T,children:[M&&jsxRuntimeExports.jsx("div",{className:clsx("button__indication",`button__indication_${qe}`),children:jsxRuntimeExports.jsx("div",{className:"button__indication-item",children:" "})}),$&&jsxRuntimeExports.jsx(m,{appearance:r(ge,Be),className:clsx(A,"button__loader"),type:Le,size:we,fill:he,itemFill:Qe}),Q,(pe||Se)&&jsxRuntimeExports.jsx(N,{appearance:r(ue,Ie),className:"button__icon_before",fill:Pe,fillSize:xe,iconFill:Te,iconSize:Ae,imageSrc:Se,shape:be,SvgImage:pe}),(ae||He)&&jsxRuntimeExports.jsx(N,{appearance:r(ye,de),className:"button__icon",fill:Fe,fillSize:Ce,iconFill:ze,iconSize:ve,imageSrc:He,shape:_e,SvgImage:ae}),(D||z)&&jsxRuntimeExports.jsx(_$1,{className:"button__label",width:O,size:U,textColor:G,textColorHover:R,textTruncate:J,textWeight:K,textWrap:V,style:We,children:D||z}),(oe||fe)&&jsxRuntimeExports.jsx(N,{appearance:r(ie,le),className:"button__icon_after",fill:ne,fillSize:te,iconFill:ce,iconSize:me,imageSrc:fe,shape:se,SvgImage:oe}),C,w]})})});
7871
7913
 
7872
7914
  var _;function nn(){return nn=Object.assign?Object.assign.bind():function(n){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var r in t)({}).hasOwnProperty.call(t,r)&&(n[r]=t[r]);}return n},nn.apply(null,arguments)}const Vn={Action:{Close:function(e){return React.createElement("svg",nn({xmlns:"http://www.w3.org/2000/svg",width:24,height:24,fill:"none",stroke:"none"},e),_||(_=React.createElement("path",{d:"M19.722 4.703a.95.95 0 0 0-1.343 0L12 11.082l-6.379-6.38a.95.95 0 1 0-1.343 1.344l6.38 6.379-6.38 6.378a.95.95 0 1 0 1.343 1.343L12 13.767l6.379 6.38a.95.95 0 1 0 1.343-1.343l-6.38-6.38 6.38-6.378a.95.95 0 0 0 0-1.343"})))}}};
7873
7915