arky-sdk 0.3.28 → 0.3.29
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.
- package/dist/index.cjs +0 -12
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -3
- package/dist/index.d.ts +1 -3
- package/dist/index.js +0 -12
- package/dist/index.js.map +1 -1
- package/dist/{svg-BhIM4HZW.d.ts → svg-CR0zPGOt.d.ts} +1 -3
- package/dist/{svg-CFjyTGXu.d.cts → svg-DKAX97qt.d.cts} +1 -3
- package/dist/types.d.cts +32 -0
- package/dist/types.d.ts +32 -0
- package/dist/utils.cjs +0 -12
- package/dist/utils.cjs.map +1 -1
- package/dist/utils.d.cts +1 -1
- package/dist/utils.d.ts +1 -1
- package/dist/utils.js +1 -11
- package/dist/utils.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { UpdateUserProfileParams, RequestOptions, AddPhoneNumberParams, PhoneNumberConfirmParams, GetMeParams, SearchUsersParams, SetRoleParams, LoginUserParams, RegisterUserParams, LogoutParams, ConfirmUserParams, GetLoginUrlParams, ForgotPasswordParams, ResetForgotPasswordParams, ResetPasswordParams, CreateBusinessParams, UpdateBusinessParams, DeleteBusinessParams, GetBusinessParams, GetBusinessesParams, GetBusinessParentsParams, TriggerBuildsParams, GetSubscriptionPlansParams, GetSubscriptionParams, UpdateSubscriptionParams, CancelSubscriptionParams, ReactivateSubscriptionParams, CreatePortalSessionParams, InviteUserParams, HandleInvitationParams, TestWebhookParams, GetBusinessMediaParams2, SetProviderScheduleParams, UploadBusinessMediaParams, DeleteBusinessMediaParams, GetBusinessMediaParams, CreateRoleParams, UpdateRoleParams, DeleteRoleParams, GetRoleParams, GetRolesParams, TrackEmailOpenParams, GetDeliveryStatsParams, CreatePromoCodeParams, UpdatePromoCodeParams, DeletePromoCodeParams, GetPromoCodeParams, GetPromoCodesParams, GetAnalyticsParams, CreateCollectionParams, UpdateCollectionParams, DeleteCollectionParams, GetCollectionParams, GetCollectionsParams, GenerateBlocksParams, GetEntriesParams, CreateEntryParams, UpdateEntryParams, DeleteCollectionEntryParams, GetCollectionEntryParams, SendEntryParams, GetVariableMetadataParams, GetCollectionSubscribersParams, SubscribeToCollectionParams, UnsubscribeFromCollectionParams, CreateProductParams, UpdateProductParams, DeleteProductParams, GetProductParams, GetProductsParams, CreateOrderParams, UpdateOrderParams, GetOrderParams, GetOrdersParams, UpdateOrderStatusParams, UpdateOrderPaymentStatusParams, GetQuoteParams, CheckoutParams, CreateReservationParams, UpdateReservationParams, ReservationCheckoutParams, GetReservationParams, GetReservationPartsParams, SearchReservationsParams, SearchMyReservationsParams, GetReservationQuoteParams, CreateServiceParams, UpdateServiceParams, DeleteServiceParams, GetServiceParams, GetServicesParams, GetAvailableSlotsParams, CreateProviderParams, UpdateProviderParams, DeleteProviderParams, GetProviderParams, GetProvidersParams, GetBusinessServiceWorkingTimeParams, HandleStripeWebhookParams, GetBusinessMarketsParams, GetBusinessMarketParams } from './types.cjs';
|
|
2
2
|
export { ApiResponse, Block, Business, EshopCartItem, EshopStoreState, Price, ReservationCartPart, ReservationStoreState } from './types.cjs';
|
|
3
|
-
import { g as
|
|
3
|
+
import { g as getBlockLabel, a as getBlockTextValue, f as formatBlockValue, p as prepareBlocksForSubmission, e as extractBlockValues, b as getMarketPrice, c as getPriceAmount, d as formatPayment, h as formatMinor, i as createPaymentForCheckout, j as getCurrencySymbol, v as validatePhoneNumber, k as findTimeZone, s as slugify, l as humanize, m as categorify, n as formatDate, o as getSvgContentForAstro, q as fetchSvgContent, r as injectSvgIntoElement } from './svg-DKAX97qt.cjs';
|
|
4
4
|
|
|
5
5
|
interface AuthTokens {
|
|
6
6
|
accessToken: string;
|
|
@@ -168,8 +168,6 @@ declare function createArkySDK(config: HttpClientConfig & {
|
|
|
168
168
|
setToken: (tokens: AuthTokens) => void;
|
|
169
169
|
utils: {
|
|
170
170
|
getImageUrl: (imageBlock: any, isBlock?: boolean) => any;
|
|
171
|
-
thumbnailUrl: (service: any) => string;
|
|
172
|
-
getGalleryThumbnail: typeof getGalleryThumbnail;
|
|
173
171
|
getBlockValue: (entry: any, blockKey: string) => any;
|
|
174
172
|
getBlockValues: (entry: any, blockKey: string) => any;
|
|
175
173
|
getBlockLabel: typeof getBlockLabel;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { UpdateUserProfileParams, RequestOptions, AddPhoneNumberParams, PhoneNumberConfirmParams, GetMeParams, SearchUsersParams, SetRoleParams, LoginUserParams, RegisterUserParams, LogoutParams, ConfirmUserParams, GetLoginUrlParams, ForgotPasswordParams, ResetForgotPasswordParams, ResetPasswordParams, CreateBusinessParams, UpdateBusinessParams, DeleteBusinessParams, GetBusinessParams, GetBusinessesParams, GetBusinessParentsParams, TriggerBuildsParams, GetSubscriptionPlansParams, GetSubscriptionParams, UpdateSubscriptionParams, CancelSubscriptionParams, ReactivateSubscriptionParams, CreatePortalSessionParams, InviteUserParams, HandleInvitationParams, TestWebhookParams, GetBusinessMediaParams2, SetProviderScheduleParams, UploadBusinessMediaParams, DeleteBusinessMediaParams, GetBusinessMediaParams, CreateRoleParams, UpdateRoleParams, DeleteRoleParams, GetRoleParams, GetRolesParams, TrackEmailOpenParams, GetDeliveryStatsParams, CreatePromoCodeParams, UpdatePromoCodeParams, DeletePromoCodeParams, GetPromoCodeParams, GetPromoCodesParams, GetAnalyticsParams, CreateCollectionParams, UpdateCollectionParams, DeleteCollectionParams, GetCollectionParams, GetCollectionsParams, GenerateBlocksParams, GetEntriesParams, CreateEntryParams, UpdateEntryParams, DeleteCollectionEntryParams, GetCollectionEntryParams, SendEntryParams, GetVariableMetadataParams, GetCollectionSubscribersParams, SubscribeToCollectionParams, UnsubscribeFromCollectionParams, CreateProductParams, UpdateProductParams, DeleteProductParams, GetProductParams, GetProductsParams, CreateOrderParams, UpdateOrderParams, GetOrderParams, GetOrdersParams, UpdateOrderStatusParams, UpdateOrderPaymentStatusParams, GetQuoteParams, CheckoutParams, CreateReservationParams, UpdateReservationParams, ReservationCheckoutParams, GetReservationParams, GetReservationPartsParams, SearchReservationsParams, SearchMyReservationsParams, GetReservationQuoteParams, CreateServiceParams, UpdateServiceParams, DeleteServiceParams, GetServiceParams, GetServicesParams, GetAvailableSlotsParams, CreateProviderParams, UpdateProviderParams, DeleteProviderParams, GetProviderParams, GetProvidersParams, GetBusinessServiceWorkingTimeParams, HandleStripeWebhookParams, GetBusinessMarketsParams, GetBusinessMarketParams } from './types.js';
|
|
2
2
|
export { ApiResponse, Block, Business, EshopCartItem, EshopStoreState, Price, ReservationCartPart, ReservationStoreState } from './types.js';
|
|
3
|
-
import { g as
|
|
3
|
+
import { g as getBlockLabel, a as getBlockTextValue, f as formatBlockValue, p as prepareBlocksForSubmission, e as extractBlockValues, b as getMarketPrice, c as getPriceAmount, d as formatPayment, h as formatMinor, i as createPaymentForCheckout, j as getCurrencySymbol, v as validatePhoneNumber, k as findTimeZone, s as slugify, l as humanize, m as categorify, n as formatDate, o as getSvgContentForAstro, q as fetchSvgContent, r as injectSvgIntoElement } from './svg-CR0zPGOt.js';
|
|
4
4
|
|
|
5
5
|
interface AuthTokens {
|
|
6
6
|
accessToken: string;
|
|
@@ -168,8 +168,6 @@ declare function createArkySDK(config: HttpClientConfig & {
|
|
|
168
168
|
setToken: (tokens: AuthTokens) => void;
|
|
169
169
|
utils: {
|
|
170
170
|
getImageUrl: (imageBlock: any, isBlock?: boolean) => any;
|
|
171
|
-
thumbnailUrl: (service: any) => string;
|
|
172
|
-
getGalleryThumbnail: typeof getGalleryThumbnail;
|
|
173
171
|
getBlockValue: (entry: any, blockKey: string) => any;
|
|
174
172
|
getBlockValues: (entry: any, blockKey: string) => any;
|
|
175
173
|
getBlockLabel: typeof getBlockLabel;
|
package/dist/index.js
CHANGED
|
@@ -1138,16 +1138,6 @@ var getImageUrl = (imageBlock, isBlock = true, storageUrl = "https://storage.ark
|
|
|
1138
1138
|
}
|
|
1139
1139
|
return null;
|
|
1140
1140
|
};
|
|
1141
|
-
function getGalleryThumbnail(gallery) {
|
|
1142
|
-
if (!gallery?.length) return null;
|
|
1143
|
-
const item = gallery.find((g) => g.settings.isThumbnail) || gallery[0];
|
|
1144
|
-
const res = item.media.resolutions.thumbnail || item.media.resolutions.original;
|
|
1145
|
-
return res?.url || null;
|
|
1146
|
-
}
|
|
1147
|
-
function thumbnailUrl(service, storageUrl = "") {
|
|
1148
|
-
const path = getGalleryThumbnail(service.gallery);
|
|
1149
|
-
return path ? `${storageUrl}/${path}` : null;
|
|
1150
|
-
}
|
|
1151
1141
|
|
|
1152
1142
|
// src/utils/currency.ts
|
|
1153
1143
|
function getCurrencySymbol(currency) {
|
|
@@ -1548,8 +1538,6 @@ function createArkySDK(config) {
|
|
|
1548
1538
|
utils: {
|
|
1549
1539
|
// Block utilities
|
|
1550
1540
|
getImageUrl: (imageBlock, isBlock = true) => getImageUrl(imageBlock, isBlock, storageUrl),
|
|
1551
|
-
thumbnailUrl: (service) => thumbnailUrl(service, storageUrl),
|
|
1552
|
-
getGalleryThumbnail,
|
|
1553
1541
|
getBlockValue,
|
|
1554
1542
|
getBlockValues,
|
|
1555
1543
|
getBlockLabel,
|