@snabcentr/common-lib 1.82.1 → 1.83.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,6 +4,6 @@
4
4
  "name": "public-api",
5
5
  "src": "src/public-api.ts",
6
6
  "isEntry": true,
7
- "integrity": "sha384-2jkVHpanGTNS/LXTFntcfgVuU1aTP3dAiD9DYEUb7ujgXPa80TRK7ZPsEAgVo8mx"
7
+ "integrity": "sha384-ZskIJNlNpMe6pAUZBI5sXxthBPbNGlJcK7sWxlRYgW8BOdebHQYEC8X3lnHFxp5C"
8
8
  }
9
9
  }
@@ -5293,7 +5293,11 @@ class Ar {
5293
5293
  return (e = r.properties) != null && e.lengthStep ? r.properties.lengthStep : !((s = r.properties) != null && s.ignoreMinCountCheck) && ((i = r.properties) != null && i.minCount) ? r.properties.minCount : 0.01;
5294
5294
  }
5295
5295
  }
5296
- class ns {
5296
+ function ns(n, r) {
5297
+ const e = [2, 0, 1, 1, 1, 2];
5298
+ return r[n % 100 > 4 && n % 100 < 20 ? 2 : e[Math.min(n % 10, 5)]];
5299
+ }
5300
+ class os {
5297
5301
  /**
5298
5302
  * Генерирует и возвращает данные-заглушку неопределённого менеджера.
5299
5303
  */
@@ -5480,7 +5484,7 @@ class Se extends $r {
5480
5484
  this.products = (e.products ?? []).map((s) => new Pt(s)), this.invoices = e.invoices ?? [], this.comment = e.comment, this.image = e.image, this.contragent = e.contragent ? we.createInstance(e.contragent) : void 0, this.barcode = e.barcode, this.orderSource = e.orderSource ? new P(e.orderSource) : void 0, this.isAllowProcessingWithoutPayment = e.isAllowProcessingWithoutPayment;
5481
5485
  }
5482
5486
  }
5483
- class os extends De {
5487
+ class cs extends De {
5484
5488
  /**
5485
5489
  * Возвращает данные о заказах, удовлетворяющих указанным параметрам поиска.
5486
5490
  *
@@ -5621,7 +5625,7 @@ const Ie = (n) => {
5621
5625
  const r = {};
5622
5626
  return n.from && (n.from.coefficient || n.from.value) && (r.from = {}, n.from.coefficient && (r.from.priceCoefficientId = n.from.coefficient.id), n.from.value && (r.from.increasePercent = n.from.value)), n.to && (n.to.coefficient || n.to.value) && (r.to = {}, n.to.coefficient && (r.to.priceCoefficientId = n.to.coefficient.id), n.to.value && (r.to.increasePercent = n.to.value)), r;
5623
5627
  };
5624
- class cs extends p {
5628
+ class ls extends p {
5625
5629
  /**
5626
5630
  * Возвращает список клиентских цен на продукты в указанном диапазоне цены.
5627
5631
  *
@@ -5747,7 +5751,7 @@ class at extends oe {
5747
5751
  this.history = pe(e.history, (s) => new Dt(s));
5748
5752
  }
5749
5753
  }
5750
- class ls extends p {
5754
+ class us extends p {
5751
5755
  /**
5752
5756
  * Возвращает данные об истории изменения цен.
5753
5757
  *
@@ -5789,7 +5793,7 @@ class rr {
5789
5793
  r != null && r.products && (this.products = r.products.map((e) => new oe(e))), r != null && r.productCategories && (this.productCategories = r.productCategories.map((e) => new oe(e)));
5790
5794
  }
5791
5795
  }
5792
- class us extends p {
5796
+ class ps extends p {
5793
5797
  /**
5794
5798
  * Возвращает данные о рекомендациях указанной категории продуктов.
5795
5799
  *
@@ -6051,7 +6055,7 @@ const A = M("common.references_private", () => {
6051
6055
  */
6052
6056
  priceCoefficientsReference: l
6053
6057
  };
6054
- }), ps = M("common.references", () => {
6058
+ }), hs = M("common.references", () => {
6055
6059
  const n = D(() => {
6056
6060
  const l = A();
6057
6061
  return !l.channelPrimaryInterestReference && !l.dataLoaderList.channelPrimaryInterestReference && (l.dataLoaderList.channelPrimaryInterestReference = !0, p.getInstance($).getChannelPrimaryInterest().then((m) => {
@@ -6266,7 +6270,7 @@ class tr {
6266
6270
  this.resourceType = new vr(r == null ? void 0 : r.resourceType), this.resourceId = (r == null ? void 0 : r.resourceId) ?? "", this.h1 = r == null ? void 0 : r.h1, this.title = r == null ? void 0 : r.title, this.description = r == null ? void 0 : r.description, this.keywords = r == null ? void 0 : r.keywords, this.meta = ((e = r == null ? void 0 : r.meta) == null ? void 0 : e.map((s) => new At(s))) ?? [];
6267
6271
  }
6268
6272
  }
6269
- class hs extends p {
6273
+ class gs extends p {
6270
6274
  /**
6271
6275
  * Возвращает {@link Promise} для получения данных о SEO-параметрах указанного ресурса.
6272
6276
  *
@@ -6297,7 +6301,7 @@ class hs extends p {
6297
6301
  return this.delete(`/internal/seo/${r.slug}/${e}`);
6298
6302
  }
6299
6303
  }
6300
- class gs extends p {
6304
+ class ms extends p {
6301
6305
  /**
6302
6306
  * Возвращает подсказки по адресам.
6303
6307
  *
@@ -6368,7 +6372,7 @@ class Tt extends fr {
6368
6372
  this.type = e == null ? void 0 : e.type, this.canDoReclamations = (e == null ? void 0 : e.canDoReclamations) ?? !1, this.photo = e == null ? void 0 : e.photo;
6369
6373
  }
6370
6374
  }
6371
- class ms extends p {
6375
+ class fs extends p {
6372
6376
  /**
6373
6377
  * Инициализирует экземпляр класса {@link UserAuthDataProvider}.
6374
6378
  */
@@ -6405,7 +6409,7 @@ const St = M("common.user_state_private", () => {
6405
6409
  */
6406
6410
  currentUser: r
6407
6411
  };
6408
- }), fs = M("common.user_state", () => ({
6412
+ }), ys = M("common.user_state", () => ({
6409
6413
  /**
6410
6414
  * Данные о текущем пользователе.
6411
6415
  */
@@ -6418,7 +6422,7 @@ const St = M("common.user_state_private", () => {
6418
6422
  })), r.currentUser;
6419
6423
  })
6420
6424
  }));
6421
- class ys {
6425
+ class ws {
6422
6426
  /**
6423
6427
  * Инициализирует экземпляр класса {@link FieldValidationResultData}.
6424
6428
  *
@@ -6488,7 +6492,7 @@ export {
6488
6492
  Fe as CuratedDirection,
6489
6493
  Me as Curator,
6490
6494
  d as Currency,
6491
- gs as DataSuggestionProvider,
6495
+ ms as DataSuggestionProvider,
6492
6496
  Zt as DataTablePagination,
6493
6497
  vt as DataTablePaginationRequestParams,
6494
6498
  es as DataTableSortRequestParams,
@@ -6499,7 +6503,7 @@ export {
6499
6503
  Nt as DetailedJwtPayload,
6500
6504
  Wr as DeviceTypeResolutionConfig,
6501
6505
  Zr as DiscountShortInfo,
6502
- ys as FieldValidationResultData,
6506
+ ws as FieldValidationResultData,
6503
6507
  le as FilterGroup,
6504
6508
  Qe as FilterItem,
6505
6509
  ze as FilterOpEnum,
@@ -6513,7 +6517,7 @@ export {
6513
6517
  H as JwtPayload,
6514
6518
  Pe as Manager,
6515
6519
  Ge as ManagerCommon,
6516
- ns as ManagerDataFactory,
6520
+ os as ManagerDataFactory,
6517
6521
  Rt as ManagerDataProvider,
6518
6522
  At as MetaTagItem,
6519
6523
  T as NamedIdentity,
@@ -6526,15 +6530,15 @@ export {
6526
6530
  ut as OrderPaymentStatus,
6527
6531
  ar as OrderShortInfo,
6528
6532
  pt as OrderStatus,
6529
- os as OrdersDataProvider,
6533
+ cs as OrdersDataProvider,
6530
6534
  X as PartnerGroup,
6531
6535
  ht as PaymentType,
6532
6536
  fe as PreferencesStorageProvider,
6533
6537
  ke as PriceAnalyze,
6534
- cs as PriceAnalyzeProvider,
6538
+ ls as PriceAnalyzeProvider,
6535
6539
  Ce as PriceCoefficient,
6536
6540
  ur as PriceCoefficientEnum,
6537
- ls as PriceHistoryDataProvider,
6541
+ us as PriceHistoryDataProvider,
6538
6542
  Dt as PriceHistoryItem,
6539
6543
  E as PriceTemplate,
6540
6544
  $e as PriceTemplateCategory,
@@ -6557,7 +6561,7 @@ export {
6557
6561
  yr as PropertyType,
6558
6562
  st as PropertyTypeEnum,
6559
6563
  J as PropertyValue,
6560
- us as RecommendationsDataProvider,
6564
+ ps as RecommendationsDataProvider,
6561
6565
  rr as RecommendationsList,
6562
6566
  P as Reference,
6563
6567
  $ as ReferenceDataProvider,
@@ -6566,7 +6570,7 @@ export {
6566
6570
  O as SalesDirection,
6567
6571
  Er as SentryConfig,
6568
6572
  tr as Seo,
6569
- hs as SeoDataProvider,
6573
+ gs as SeoDataProvider,
6570
6574
  Cr as SourcePrimaryInterest,
6571
6575
  et as StockCount,
6572
6576
  Qt as TemplateProductCategoryDataProvider,
@@ -6576,7 +6580,7 @@ export {
6576
6580
  rs as UnknownClientDataProvider,
6577
6581
  cr as UpdatableNamedIdentity,
6578
6582
  Tt as User,
6579
- ms as UserAuthDataProvider,
6583
+ fs as UserAuthDataProvider,
6580
6584
  fr as UserCommonInfo,
6581
6585
  bt as UserDataProvider,
6582
6586
  it as UserPricingRole,
@@ -6587,8 +6591,9 @@ export {
6587
6591
  Vr as WebSocketConfig,
6588
6592
  Ye as findCatalogItemByIdRecursive,
6589
6593
  Xe as flattenCatalogItems,
6594
+ ns as pluralize,
6590
6595
  Ae as useAuthStateStore,
6591
6596
  k as useBaseConfigStateStore,
6592
- ps as useReferencesStore,
6593
- fs as useUserStateStore
6597
+ hs as useReferencesStore,
6598
+ ys as useUserStateStore
6594
6599
  };