@deenruv/admin-dashboard 1.0.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.
- package/LICENSE +23 -0
- package/README.md +30 -0
- package/dist/@types/resources.js +51 -0
- package/dist/DeenruvAdminPanel.js +118 -0
- package/dist/DeenruvDeveloperIndicator.js +57 -0
- package/dist/components/Aexol.js +4 -0
- package/dist/components/BrandLogo.js +22 -0
- package/dist/components/CanLeaveRouteDialog.js +8 -0
- package/dist/components/DataTable.js +13 -0
- package/dist/components/DeleteDialog.js +6 -0
- package/dist/components/DuplicateEntry.js +46 -0
- package/dist/components/GlobalSearch.js +134 -0
- package/dist/components/History/AddEntryForm.js +29 -0
- package/dist/components/History/DeleteEntryDialog.js +25 -0
- package/dist/components/History/EditEntryDialog.js +32 -0
- package/dist/components/History/History.js +13 -0
- package/dist/components/History/ModifyHistoryInfo.js +6 -0
- package/dist/components/History/Timeline.js +53 -0
- package/dist/components/History/index.js +5 -0
- package/dist/components/Menu/ActiveAdmins.js +24 -0
- package/dist/components/Menu/ChannelSwitcher.js +20 -0
- package/dist/components/Menu/LanguagesDropdown.js +26 -0
- package/dist/components/Menu/Navigation.js +270 -0
- package/dist/components/Menu/NavigationFooter.js +12 -0
- package/dist/components/Menu/Notifications.js +90 -0
- package/dist/components/Menu/index.js +67 -0
- package/dist/components/index.js +6 -0
- package/dist/graphql/base.js +95 -0
- package/dist/graphql/collections.js +94 -0
- package/dist/graphql/draft_order.js +307 -0
- package/dist/graphql/orders.js +157 -0
- package/dist/graphql/products.js +230 -0
- package/dist/graphql/scalars.js +22 -0
- package/dist/i18.js +13 -0
- package/dist/index.css +161 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +1 -0
- package/dist/locales/en/admins.json +57 -0
- package/dist/locales/en/assets.json +69 -0
- package/dist/locales/en/channels.json +66 -0
- package/dist/locales/en/collections.json +145 -0
- package/dist/locales/en/common.json +1127 -0
- package/dist/locales/en/countries.json +50 -0
- package/dist/locales/en/customerGroups.json +6 -0
- package/dist/locales/en/customers.json +109 -0
- package/dist/locales/en/dashboard.json +34 -0
- package/dist/locales/en/facets.json +78 -0
- package/dist/locales/en/globalSettings.json +15 -0
- package/dist/locales/en/index.js +52 -0
- package/dist/locales/en/orders.json +932 -0
- package/dist/locales/en/paymentMethods.json +59 -0
- package/dist/locales/en/permissions.json +94 -0
- package/dist/locales/en/products.json +194 -0
- package/dist/locales/en/promotions.json +65 -0
- package/dist/locales/en/roles.json +59 -0
- package/dist/locales/en/sellers.json +41 -0
- package/dist/locales/en/shippingMethods.json +84 -0
- package/dist/locales/en/stockLocations.json +40 -0
- package/dist/locales/en/system.json +41 -0
- package/dist/locales/en/table.json +201 -0
- package/dist/locales/en/taxCategories.json +47 -0
- package/dist/locales/en/taxRates.json +56 -0
- package/dist/locales/en/zones.json +47 -0
- package/dist/locales/index.js +2 -0
- package/dist/locales/pl/admins.json +57 -0
- package/dist/locales/pl/assets.json +69 -0
- package/dist/locales/pl/channels.json +66 -0
- package/dist/locales/pl/collections.json +145 -0
- package/dist/locales/pl/common.json +1128 -0
- package/dist/locales/pl/countries.json +50 -0
- package/dist/locales/pl/customerGroups.json +6 -0
- package/dist/locales/pl/customers.json +109 -0
- package/dist/locales/pl/dashboard.json +34 -0
- package/dist/locales/pl/facets.json +78 -0
- package/dist/locales/pl/globalSettings.json +15 -0
- package/dist/locales/pl/index.js +52 -0
- package/dist/locales/pl/orders.json +932 -0
- package/dist/locales/pl/paymentMethods.json +59 -0
- package/dist/locales/pl/permissions.json +94 -0
- package/dist/locales/pl/products.json +194 -0
- package/dist/locales/pl/promotions.json +65 -0
- package/dist/locales/pl/roles.json +59 -0
- package/dist/locales/pl/sellers.json +41 -0
- package/dist/locales/pl/shippingMethods.json +84 -0
- package/dist/locales/pl/stockLocations.json +40 -0
- package/dist/locales/pl/system.json +41 -0
- package/dist/locales/pl/table.json +201 -0
- package/dist/locales/pl/taxCategories.json +47 -0
- package/dist/locales/pl/taxRates.json +56 -0
- package/dist/locales/pl/zones.json +47 -0
- package/dist/notifications/OrderStatusNotification.js +47 -0
- package/dist/notifications/SystemStatusNotification.js +19 -0
- package/dist/pages/Custom404.js +5 -0
- package/dist/pages/LoginScreen.js +37 -0
- package/dist/pages/Root.js +252 -0
- package/dist/pages/admins/Detail.js +72 -0
- package/dist/pages/admins/List.js +56 -0
- package/dist/pages/admins/_components/AdminDetailView.js +34 -0
- package/dist/pages/admins/_components/RolesCard.js +31 -0
- package/dist/pages/admins/index.js +2 -0
- package/dist/pages/assets/List.js +82 -0
- package/dist/pages/assets/_components/Asset.js +114 -0
- package/dist/pages/assets/_components/AssetListView.js +29 -0
- package/dist/pages/assets/_components/EditAssetDialog.js +85 -0
- package/dist/pages/assets/_components/UploadAssetDialog.js +133 -0
- package/dist/pages/assets/_components/UploadProgress.js +20 -0
- package/dist/pages/assets/index.js +1 -0
- package/dist/pages/channels/Detail.js +149 -0
- package/dist/pages/channels/List.js +46 -0
- package/dist/pages/channels/_components/ChannelDetailView.js +51 -0
- package/dist/pages/channels/_components/DefaultsCard.js +25 -0
- package/dist/pages/channels/index.js +2 -0
- package/dist/pages/collections/Detail.js +61 -0
- package/dist/pages/collections/List.js +135 -0
- package/dist/pages/collections/_components/CollectionDetailView.js +52 -0
- package/dist/pages/collections/_components/CollectionProductVariantsDrawer.js +28 -0
- package/dist/pages/collections/_components/CombinationMode.js +6 -0
- package/dist/pages/collections/_components/ContentsCard.js +43 -0
- package/dist/pages/collections/_components/ContentsTable.js +102 -0
- package/dist/pages/collections/_components/DeleteCollectionsFromChannel.js +36 -0
- package/dist/pages/collections/_components/FacetsSelector.js +30 -0
- package/dist/pages/collections/_components/FiltersCard.js +101 -0
- package/dist/pages/collections/_components/MoveCollectionsToCollections.js +107 -0
- package/dist/pages/collections/_components/MoveEntityToChannels.js +115 -0
- package/dist/pages/collections/_components/PageHeader.js +11 -0
- package/dist/pages/collections/_components/SelectedCollectionsModal.js +22 -0
- package/dist/pages/collections/_components/VariantsSelector.js +43 -0
- package/dist/pages/collections/consts.js +7 -0
- package/dist/pages/collections/index.js +2 -0
- package/dist/pages/countries/Detail.js +57 -0
- package/dist/pages/countries/List.js +47 -0
- package/dist/pages/countries/_components/CountryDetailView.js +28 -0
- package/dist/pages/countries/index.js +2 -0
- package/dist/pages/customer-groups/Detail.js +76 -0
- package/dist/pages/customer-groups/List.js +41 -0
- package/dist/pages/customer-groups/_components/CustomerGroupsDetailView.js +21 -0
- package/dist/pages/customer-groups/index.js +2 -0
- package/dist/pages/customers/Detail.js +75 -0
- package/dist/pages/customers/List.js +60 -0
- package/dist/pages/customers/_components/Address.js +59 -0
- package/dist/pages/customers/_components/AddressDialog.js +56 -0
- package/dist/pages/customers/_components/AddressForm.js +77 -0
- package/dist/pages/customers/_components/AddressesCard.js +9 -0
- package/dist/pages/customers/_components/CustomerDetailSidebar.js +9 -0
- package/dist/pages/customers/_components/CustomerDetailView.js +41 -0
- package/dist/pages/customers/_components/CustomerGroupsCard.js +46 -0
- package/dist/pages/customers/_components/HistoryTab.js +65 -0
- package/dist/pages/customers/_components/OrdersTab.js +46 -0
- package/dist/pages/customers/_components/PersonalDataCard.js +6 -0
- package/dist/pages/customers/_components/VerifiedCard.js +6 -0
- package/dist/pages/customers/index.js +2 -0
- package/dist/pages/dashboard/Dashboard.js +10 -0
- package/dist/pages/dashboard/index.js +1 -0
- package/dist/pages/extensions/Extensions.js +74 -0
- package/dist/pages/extensions/index.js +1 -0
- package/dist/pages/facets/Detail.js +56 -0
- package/dist/pages/facets/List.js +48 -0
- package/dist/pages/facets/_components/AddFacetValueDialog.js +105 -0
- package/dist/pages/facets/_components/ColorSample.js +18 -0
- package/dist/pages/facets/_components/FacetDetailView.js +98 -0
- package/dist/pages/facets/index.js +2 -0
- package/dist/pages/global-settings/GlobalSettingsComponent.js +30 -0
- package/dist/pages/global-settings/index.js +71 -0
- package/dist/pages/index.js +25 -0
- package/dist/pages/orders/Detail.js +21 -0
- package/dist/pages/orders/List.js +132 -0
- package/dist/pages/orders/_components/AddPaymentDialog.js +50 -0
- package/dist/pages/orders/_components/AddressCard.js +260 -0
- package/dist/pages/orders/_components/CancelAndRefundDialog.js +29 -0
- package/dist/pages/orders/_components/ChangesRegister.js +68 -0
- package/dist/pages/orders/_components/ChangesRegisterTable.js +18 -0
- package/dist/pages/orders/_components/CouponCodesCard.js +85 -0
- package/dist/pages/orders/_components/CustomComponent.js +21 -0
- package/dist/pages/orders/_components/CustomerSelectCard.js +117 -0
- package/dist/pages/orders/_components/EditNoteButton.js +10 -0
- package/dist/pages/orders/_components/FulfillmentModal.js +85 -0
- package/dist/pages/orders/_components/LineItem.js +7 -0
- package/dist/pages/orders/_components/ManualOrderChangeModal.js +47 -0
- package/dist/pages/orders/_components/ModifyAcceptModal.js +22 -0
- package/dist/pages/orders/_components/ModifyingCard.js +77 -0
- package/dist/pages/orders/_components/OrderHistory.js +59 -0
- package/dist/pages/orders/_components/OrderLineActionModal/ActionQuantityPrice.js +58 -0
- package/dist/pages/orders/_components/OrderLineActionModal/index.js +7 -0
- package/dist/pages/orders/_components/OrderLineActionModal/types.js +1 -0
- package/dist/pages/orders/_components/OrderLineCustomFields.js +26 -0
- package/dist/pages/orders/_components/OrderSummary.js +10 -0
- package/dist/pages/orders/_components/PaymentMetadata.js +6 -0
- package/dist/pages/orders/_components/Payments.js +113 -0
- package/dist/pages/orders/_components/PossibleOrderStates.js +54 -0
- package/dist/pages/orders/_components/PriceChangedInfo.js +16 -0
- package/dist/pages/orders/_components/ProductsCard.js +308 -0
- package/dist/pages/orders/_components/ProductsTable.js +29 -0
- package/dist/pages/orders/_components/PromotionsList.js +73 -0
- package/dist/pages/orders/_components/RealizationCard.js +98 -0
- package/dist/pages/orders/_components/RefundCard.js +11 -0
- package/dist/pages/orders/_components/RefundPaymentCard.js +13 -0
- package/dist/pages/orders/_components/ShippingMethod.js +112 -0
- package/dist/pages/orders/_components/SpecialLineItem.js +7 -0
- package/dist/pages/orders/_components/SurchargeCard.js +99 -0
- package/dist/pages/orders/_components/SurchargeTable.js +8 -0
- package/dist/pages/orders/_components/TaxSummary.js +11 -0
- package/dist/pages/orders/_components/ToRealizationForm.js +64 -0
- package/dist/pages/orders/_components/TopActions.js +219 -0
- package/dist/pages/orders/_components/index.js +25 -0
- package/dist/pages/orders/index.js +2 -0
- package/dist/pages/payment-methods/Detail.js +67 -0
- package/dist/pages/payment-methods/List.js +41 -0
- package/dist/pages/payment-methods/_components/OptionsCard.js +60 -0
- package/dist/pages/payment-methods/_components/PaymentMethodDetailView.js +53 -0
- package/dist/pages/payment-methods/index.js +2 -0
- package/dist/pages/product-variants/Detail.js +4 -0
- package/dist/pages/product-variants/List.js +76 -0
- package/dist/pages/product-variants/index.js +2 -0
- package/dist/pages/products/Detail.js +75 -0
- package/dist/pages/products/List.js +79 -0
- package/dist/pages/products/_components/AddOptionGroupDialog.js +65 -0
- package/dist/pages/products/_components/AssetsCard.js +35 -0
- package/dist/pages/products/_components/BasicFieldsCard.js +6 -0
- package/dist/pages/products/_components/ChannelsCard.js +6 -0
- package/dist/pages/products/_components/CollectionsCard.js +6 -0
- package/dist/pages/products/_components/Container.js +4 -0
- package/dist/pages/products/_components/DiscountRatingCard.js +6 -0
- package/dist/pages/products/_components/FacetValuesCard.js +6 -0
- package/dist/pages/products/_components/ImagesCard.js +6 -0
- package/dist/pages/products/_components/OptionGroup.js +93 -0
- package/dist/pages/products/_components/OptionValueCard.js +59 -0
- package/dist/pages/products/_components/OptionsCard.js +38 -0
- package/dist/pages/products/_components/OptionsTab.js +40 -0
- package/dist/pages/products/_components/PriceCard.js +27 -0
- package/dist/pages/products/_components/ProductDetailSidebar.js +30 -0
- package/dist/pages/products/_components/ProductDetailView.js +54 -0
- package/dist/pages/products/_components/SettingsCard.js +6 -0
- package/dist/pages/products/_components/StockCard.js +40 -0
- package/dist/pages/products/_components/Variant.js +149 -0
- package/dist/pages/products/_components/VariantsTab.js +46 -0
- package/dist/pages/products/index.js +2 -0
- package/dist/pages/promotions/Detail.js +80 -0
- package/dist/pages/promotions/List.js +38 -0
- package/dist/pages/promotions/_components/ActionsCard.js +67 -0
- package/dist/pages/promotions/_components/BasicFieldsCard.js +6 -0
- package/dist/pages/promotions/_components/ConditionsCard.js +70 -0
- package/dist/pages/promotions/_components/CustomerGroupsSelector.js +25 -0
- package/dist/pages/promotions/_components/EnabledCard.js +6 -0
- package/dist/pages/promotions/_components/OptionsCard.js +6 -0
- package/dist/pages/promotions/_components/PromotionDetailSidebar.js +15 -0
- package/dist/pages/promotions/_components/PromotionDetailView.js +66 -0
- package/dist/pages/promotions/_components/PromotionFieldRender.js +4 -0
- package/dist/pages/promotions/index.js +2 -0
- package/dist/pages/roles/Detail.js +72 -0
- package/dist/pages/roles/List.js +70 -0
- package/dist/pages/roles/_components/PermissionsCard.js +7 -0
- package/dist/pages/roles/_components/PermissionsTable.js +42 -0
- package/dist/pages/roles/_components/RoleDetailView.js +49 -0
- package/dist/pages/roles/index.js +2 -0
- package/dist/pages/sellers/Detail.js +48 -0
- package/dist/pages/sellers/List.js +37 -0
- package/dist/pages/sellers/_components/SellerDetailView.js +20 -0
- package/dist/pages/sellers/index.js +2 -0
- package/dist/pages/shipping-methods/Detail.js +105 -0
- package/dist/pages/shipping-methods/List.js +40 -0
- package/dist/pages/shipping-methods/_components/CalculatorCard.js +79 -0
- package/dist/pages/shipping-methods/_components/CheckerCard.js +76 -0
- package/dist/pages/shipping-methods/_components/Lines.js +20 -0
- package/dist/pages/shipping-methods/_components/ShippingMethodDetailView.js +67 -0
- package/dist/pages/shipping-methods/_components/TestCard.js +62 -0
- package/dist/pages/shipping-methods/index.js +2 -0
- package/dist/pages/status/Status.js +6 -0
- package/dist/pages/status/_components/FilterToolbar.js +29 -0
- package/dist/pages/status/_components/Health.js +21 -0
- package/dist/pages/status/_components/JobResultPopover.js +8 -0
- package/dist/pages/status/_components/Jobs.js +199 -0
- package/dist/pages/status/_components/JsonExplorer.js +44 -0
- package/dist/pages/status/_components/JsonPopup.js +8 -0
- package/dist/pages/status/index.js +1 -0
- package/dist/pages/stock-locations/Detail.js +77 -0
- package/dist/pages/stock-locations/List.js +38 -0
- package/dist/pages/stock-locations/_components/StockLocationDetailView.js +22 -0
- package/dist/pages/stock-locations/index.js +2 -0
- package/dist/pages/tax-categories/Detail.js +85 -0
- package/dist/pages/tax-categories/List.js +46 -0
- package/dist/pages/tax-categories/_components/TaxCategoryDetailView.js +24 -0
- package/dist/pages/tax-categories/index.js +2 -0
- package/dist/pages/tax-rates/Detail.js +62 -0
- package/dist/pages/tax-rates/List.js +64 -0
- package/dist/pages/tax-rates/_components/TaxRateDetailView.js +64 -0
- package/dist/pages/tax-rates/index.js +2 -0
- package/dist/pages/zones/Detail.js +86 -0
- package/dist/pages/zones/List.js +52 -0
- package/dist/pages/zones/_components/ZoneDetailView.js +49 -0
- package/dist/pages/zones/index.js +2 -0
- package/dist/version.js +1 -0
- package/package.json +122 -0
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
import { Selector } from '@deenruv/admin-types';
|
|
2
|
+
export const paymentSelector = Selector('Payment')({
|
|
3
|
+
id: true,
|
|
4
|
+
method: true,
|
|
5
|
+
amount: true,
|
|
6
|
+
state: true,
|
|
7
|
+
errorMessage: true,
|
|
8
|
+
createdAt: true,
|
|
9
|
+
metadata: true,
|
|
10
|
+
transactionId: true,
|
|
11
|
+
});
|
|
12
|
+
export const discountsSelector = Selector('Discount')({
|
|
13
|
+
type: true,
|
|
14
|
+
description: true,
|
|
15
|
+
amountWithTax: true,
|
|
16
|
+
adjustmentSource: true,
|
|
17
|
+
});
|
|
18
|
+
export const shippingLineSelector = Selector('ShippingLine')({
|
|
19
|
+
shippingMethod: {
|
|
20
|
+
id: true,
|
|
21
|
+
name: true,
|
|
22
|
+
description: true,
|
|
23
|
+
},
|
|
24
|
+
priceWithTax: true,
|
|
25
|
+
});
|
|
26
|
+
export const ShippingMethodsSelector = Selector('ShippingMethodQuote')({
|
|
27
|
+
id: true,
|
|
28
|
+
name: true,
|
|
29
|
+
price: true,
|
|
30
|
+
description: true,
|
|
31
|
+
});
|
|
32
|
+
export const ActiveOrderSelector = Selector('Order')({
|
|
33
|
+
id: true,
|
|
34
|
+
createdAt: true,
|
|
35
|
+
updatedAt: true,
|
|
36
|
+
totalQuantity: true,
|
|
37
|
+
couponCodes: true,
|
|
38
|
+
code: true,
|
|
39
|
+
customer: { id: true, emailAddress: true, firstName: true, lastName: true, phoneNumber: true },
|
|
40
|
+
shippingWithTax: true,
|
|
41
|
+
totalWithTax: true,
|
|
42
|
+
subTotalWithTax: true,
|
|
43
|
+
discounts: discountsSelector,
|
|
44
|
+
state: true,
|
|
45
|
+
active: true,
|
|
46
|
+
payments: paymentSelector,
|
|
47
|
+
currencyCode: true,
|
|
48
|
+
shippingLines: shippingLineSelector,
|
|
49
|
+
lines: {
|
|
50
|
+
id: true,
|
|
51
|
+
quantity: true,
|
|
52
|
+
linePriceWithTax: true,
|
|
53
|
+
unitPriceWithTax: true,
|
|
54
|
+
discountedLinePriceWithTax: true,
|
|
55
|
+
featuredAsset: {
|
|
56
|
+
id: true,
|
|
57
|
+
preview: true,
|
|
58
|
+
},
|
|
59
|
+
productVariant: {
|
|
60
|
+
name: true,
|
|
61
|
+
id: true,
|
|
62
|
+
sku: true,
|
|
63
|
+
price: true,
|
|
64
|
+
featuredAsset: {
|
|
65
|
+
id: true,
|
|
66
|
+
source: true,
|
|
67
|
+
},
|
|
68
|
+
stockLevel: true,
|
|
69
|
+
product: {
|
|
70
|
+
name: true,
|
|
71
|
+
slug: true,
|
|
72
|
+
},
|
|
73
|
+
},
|
|
74
|
+
},
|
|
75
|
+
});
|
|
76
|
+
export const LatestOrderSelector = Selector('Order')({
|
|
77
|
+
totalWithTax: true,
|
|
78
|
+
state: true,
|
|
79
|
+
createdAt: true,
|
|
80
|
+
code: true,
|
|
81
|
+
id: true,
|
|
82
|
+
currencyCode: true,
|
|
83
|
+
payments: {
|
|
84
|
+
method: true,
|
|
85
|
+
id: true,
|
|
86
|
+
},
|
|
87
|
+
});
|
|
88
|
+
export const SummaryOrdersSelector = Selector('Order')({
|
|
89
|
+
total: true,
|
|
90
|
+
totalWithTax: true,
|
|
91
|
+
currencyCode: true,
|
|
92
|
+
});
|
|
93
|
+
export const OrderListSelector = Selector('Order')({
|
|
94
|
+
type: true,
|
|
95
|
+
totalWithTax: true,
|
|
96
|
+
state: true,
|
|
97
|
+
active: true,
|
|
98
|
+
currencyCode: true,
|
|
99
|
+
createdAt: true,
|
|
100
|
+
updatedAt: true,
|
|
101
|
+
shipping: true,
|
|
102
|
+
totalQuantity: true,
|
|
103
|
+
orderPlacedAt: true,
|
|
104
|
+
code: true,
|
|
105
|
+
id: true,
|
|
106
|
+
payments: {
|
|
107
|
+
method: true,
|
|
108
|
+
createdAt: true,
|
|
109
|
+
state: true,
|
|
110
|
+
},
|
|
111
|
+
shippingAddress: {
|
|
112
|
+
fullName: true,
|
|
113
|
+
},
|
|
114
|
+
customer: {
|
|
115
|
+
id: true,
|
|
116
|
+
emailAddress: true,
|
|
117
|
+
firstName: true,
|
|
118
|
+
lastName: true,
|
|
119
|
+
phoneNumber: true,
|
|
120
|
+
},
|
|
121
|
+
});
|
|
122
|
+
export const OrderSelector = Selector('Order')({
|
|
123
|
+
type: true,
|
|
124
|
+
shippingWithTax: true,
|
|
125
|
+
totalWithTax: true,
|
|
126
|
+
subTotalWithTax: true,
|
|
127
|
+
discounts: discountsSelector,
|
|
128
|
+
state: true,
|
|
129
|
+
active: true,
|
|
130
|
+
payments: paymentSelector,
|
|
131
|
+
currencyCode: true,
|
|
132
|
+
shippingLines: shippingLineSelector,
|
|
133
|
+
id: true,
|
|
134
|
+
lines: {
|
|
135
|
+
id: true,
|
|
136
|
+
quantity: true,
|
|
137
|
+
linePriceWithTax: true,
|
|
138
|
+
unitPriceWithTax: true,
|
|
139
|
+
discountedLinePriceWithTax: true,
|
|
140
|
+
featuredAsset: {
|
|
141
|
+
id: true,
|
|
142
|
+
preview: true,
|
|
143
|
+
},
|
|
144
|
+
productVariant: {
|
|
145
|
+
name: true,
|
|
146
|
+
currencyCode: true,
|
|
147
|
+
featuredAsset: {
|
|
148
|
+
id: true,
|
|
149
|
+
source: true,
|
|
150
|
+
},
|
|
151
|
+
product: {
|
|
152
|
+
slug: true,
|
|
153
|
+
name: true,
|
|
154
|
+
},
|
|
155
|
+
},
|
|
156
|
+
},
|
|
157
|
+
});
|
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
import { Selector } from '@deenruv/admin-types';
|
|
2
|
+
export const FacetSelector = Selector('Facet')({
|
|
3
|
+
id: true,
|
|
4
|
+
name: true,
|
|
5
|
+
code: true,
|
|
6
|
+
});
|
|
7
|
+
export const ProductTileSelector = Selector('Product')({
|
|
8
|
+
id: true,
|
|
9
|
+
name: true,
|
|
10
|
+
slug: true,
|
|
11
|
+
updatedAt: true,
|
|
12
|
+
enabled: true,
|
|
13
|
+
createdAt: true,
|
|
14
|
+
collections: {
|
|
15
|
+
name: true,
|
|
16
|
+
slug: true,
|
|
17
|
+
},
|
|
18
|
+
variantList: [{}, { totalItems: true }],
|
|
19
|
+
featuredAsset: {
|
|
20
|
+
source: true,
|
|
21
|
+
preview: true,
|
|
22
|
+
},
|
|
23
|
+
});
|
|
24
|
+
export const ProductSearchSelector = Selector('SearchResult')({
|
|
25
|
+
productName: true,
|
|
26
|
+
slug: true,
|
|
27
|
+
collectionIds: true,
|
|
28
|
+
currencyCode: true,
|
|
29
|
+
productVariantId: true,
|
|
30
|
+
productVariantName: true,
|
|
31
|
+
priceWithTax: {
|
|
32
|
+
'...on PriceRange': {
|
|
33
|
+
max: true,
|
|
34
|
+
min: true,
|
|
35
|
+
},
|
|
36
|
+
'...on SinglePrice': {
|
|
37
|
+
value: true,
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
facetIds: true,
|
|
41
|
+
facetValueIds: true,
|
|
42
|
+
productAsset: {
|
|
43
|
+
preview: true,
|
|
44
|
+
},
|
|
45
|
+
description: true,
|
|
46
|
+
});
|
|
47
|
+
export const SearchSelector = Selector('SearchResponse')({
|
|
48
|
+
items: ProductSearchSelector,
|
|
49
|
+
totalItems: true,
|
|
50
|
+
facetValues: {
|
|
51
|
+
count: true,
|
|
52
|
+
facetValue: {
|
|
53
|
+
...FacetSelector,
|
|
54
|
+
facet: FacetSelector,
|
|
55
|
+
},
|
|
56
|
+
},
|
|
57
|
+
});
|
|
58
|
+
export const ProductSlugSelector = Selector('Product')({
|
|
59
|
+
name: true,
|
|
60
|
+
description: true,
|
|
61
|
+
id: true,
|
|
62
|
+
slug: true,
|
|
63
|
+
facetValues: {
|
|
64
|
+
name: true,
|
|
65
|
+
code: true,
|
|
66
|
+
},
|
|
67
|
+
});
|
|
68
|
+
export const ProductDetailsFacetSelector = Selector('FacetValue')({
|
|
69
|
+
name: true,
|
|
70
|
+
id: true,
|
|
71
|
+
translations: { name: true, languageCode: true, id: true },
|
|
72
|
+
});
|
|
73
|
+
export const ProductOptionSelector = Selector('ProductOption')({
|
|
74
|
+
name: true,
|
|
75
|
+
id: true,
|
|
76
|
+
code: true,
|
|
77
|
+
translations: {
|
|
78
|
+
languageCode: true,
|
|
79
|
+
name: true,
|
|
80
|
+
},
|
|
81
|
+
});
|
|
82
|
+
export const StockLevelsSelector = Selector('StockLevel')({
|
|
83
|
+
stockLocationId: true,
|
|
84
|
+
id: true,
|
|
85
|
+
stockOnHand: true,
|
|
86
|
+
stockLocation: {
|
|
87
|
+
name: true,
|
|
88
|
+
id: true,
|
|
89
|
+
},
|
|
90
|
+
stockAllocated: true,
|
|
91
|
+
});
|
|
92
|
+
export const ProductVariantSelector = Selector('ProductVariant')({
|
|
93
|
+
id: true,
|
|
94
|
+
name: true,
|
|
95
|
+
currencyCode: true,
|
|
96
|
+
priceWithTax: true,
|
|
97
|
+
stockOnHand: true,
|
|
98
|
+
outOfStockThreshold: true,
|
|
99
|
+
useGlobalOutOfStockThreshold: true,
|
|
100
|
+
stockLevel: true,
|
|
101
|
+
trackInventory: true,
|
|
102
|
+
stockAllocated: true,
|
|
103
|
+
stockLevels: StockLevelsSelector,
|
|
104
|
+
sku: true,
|
|
105
|
+
price: true,
|
|
106
|
+
channels: {
|
|
107
|
+
id: true,
|
|
108
|
+
code: true,
|
|
109
|
+
},
|
|
110
|
+
assets: {
|
|
111
|
+
id: true,
|
|
112
|
+
name: true,
|
|
113
|
+
},
|
|
114
|
+
featuredAsset: {
|
|
115
|
+
id: true,
|
|
116
|
+
},
|
|
117
|
+
translations: {
|
|
118
|
+
name: true,
|
|
119
|
+
languageCode: true,
|
|
120
|
+
},
|
|
121
|
+
taxCategory: {
|
|
122
|
+
name: true,
|
|
123
|
+
id: true,
|
|
124
|
+
},
|
|
125
|
+
taxRateApplied: {
|
|
126
|
+
name: true,
|
|
127
|
+
id: true,
|
|
128
|
+
},
|
|
129
|
+
prices: {
|
|
130
|
+
currencyCode: true,
|
|
131
|
+
price: true,
|
|
132
|
+
},
|
|
133
|
+
options: {
|
|
134
|
+
name: true,
|
|
135
|
+
group: {
|
|
136
|
+
name: true,
|
|
137
|
+
},
|
|
138
|
+
},
|
|
139
|
+
facetValues: ProductDetailsFacetSelector,
|
|
140
|
+
});
|
|
141
|
+
export const OptionGroupSelector = Selector('ProductOptionGroup')({
|
|
142
|
+
name: true,
|
|
143
|
+
id: true,
|
|
144
|
+
code: true,
|
|
145
|
+
options: ProductOptionSelector,
|
|
146
|
+
});
|
|
147
|
+
export const ProductDetailSelector = Selector('Product')({
|
|
148
|
+
name: true,
|
|
149
|
+
description: true,
|
|
150
|
+
id: true,
|
|
151
|
+
slug: true,
|
|
152
|
+
enabled: true,
|
|
153
|
+
createdAt: true,
|
|
154
|
+
updatedAt: true,
|
|
155
|
+
channels: {
|
|
156
|
+
id: true,
|
|
157
|
+
code: true,
|
|
158
|
+
},
|
|
159
|
+
translations: {
|
|
160
|
+
languageCode: true,
|
|
161
|
+
name: true,
|
|
162
|
+
slug: true,
|
|
163
|
+
description: true,
|
|
164
|
+
id: true,
|
|
165
|
+
},
|
|
166
|
+
assets: {
|
|
167
|
+
source: true,
|
|
168
|
+
preview: true,
|
|
169
|
+
id: true,
|
|
170
|
+
},
|
|
171
|
+
collections: {
|
|
172
|
+
slug: true,
|
|
173
|
+
name: true,
|
|
174
|
+
parent: { slug: true },
|
|
175
|
+
},
|
|
176
|
+
featuredAsset: {
|
|
177
|
+
source: true,
|
|
178
|
+
preview: true,
|
|
179
|
+
id: true,
|
|
180
|
+
},
|
|
181
|
+
facetValues: ProductDetailsFacetSelector,
|
|
182
|
+
});
|
|
183
|
+
export const YAMLProductsSelector = Selector('Product')({
|
|
184
|
+
id: true,
|
|
185
|
+
name: true,
|
|
186
|
+
slug: true,
|
|
187
|
+
featuredAsset: {
|
|
188
|
+
source: true,
|
|
189
|
+
preview: true,
|
|
190
|
+
},
|
|
191
|
+
collections: {
|
|
192
|
+
name: true,
|
|
193
|
+
slug: true,
|
|
194
|
+
},
|
|
195
|
+
variants: {
|
|
196
|
+
id: true,
|
|
197
|
+
name: true,
|
|
198
|
+
currencyCode: true,
|
|
199
|
+
priceWithTax: true,
|
|
200
|
+
stockLevel: true,
|
|
201
|
+
assets: {
|
|
202
|
+
source: true,
|
|
203
|
+
preview: true,
|
|
204
|
+
},
|
|
205
|
+
featuredAsset: {
|
|
206
|
+
source: true,
|
|
207
|
+
preview: true,
|
|
208
|
+
},
|
|
209
|
+
},
|
|
210
|
+
});
|
|
211
|
+
export const productVariantTileSelector = Selector('ProductVariant')({
|
|
212
|
+
id: true,
|
|
213
|
+
name: true,
|
|
214
|
+
currencyCode: true,
|
|
215
|
+
priceWithTax: true,
|
|
216
|
+
featuredAsset: { preview: true },
|
|
217
|
+
product: {
|
|
218
|
+
collections: { slug: true, name: true, parent: { slug: true } },
|
|
219
|
+
slug: true,
|
|
220
|
+
featuredAsset: { preview: true },
|
|
221
|
+
},
|
|
222
|
+
});
|
|
223
|
+
export const NewestProductSelector = Selector('Product')({
|
|
224
|
+
name: true,
|
|
225
|
+
slug: true,
|
|
226
|
+
featuredAsset: {
|
|
227
|
+
source: true,
|
|
228
|
+
preview: true,
|
|
229
|
+
},
|
|
230
|
+
});
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ZeusScalars } from '@deenruv/admin-types';
|
|
2
|
+
export const scalars = ZeusScalars({
|
|
3
|
+
Money: {
|
|
4
|
+
decode: (e) => e,
|
|
5
|
+
},
|
|
6
|
+
DateTime: {
|
|
7
|
+
decode: (e) => new Date(e).toISOString(),
|
|
8
|
+
},
|
|
9
|
+
JSON: {
|
|
10
|
+
encode: (e) => {
|
|
11
|
+
return JSON.stringify(e).replace(/"(\w+)":/g, '$1:');
|
|
12
|
+
},
|
|
13
|
+
decode: (e) => {
|
|
14
|
+
try {
|
|
15
|
+
return JSON.parse(e);
|
|
16
|
+
}
|
|
17
|
+
catch {
|
|
18
|
+
return e;
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
},
|
|
22
|
+
});
|
package/dist/i18.js
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import i18next from 'i18next';
|
|
2
|
+
// eslint-disable-next-line no-restricted-imports
|
|
3
|
+
import { initReactI18next } from 'react-i18next';
|
|
4
|
+
import LanguageDetector from 'i18next-browser-languagedetector';
|
|
5
|
+
import { useSettings } from '@deenruv/react-ui-devkit';
|
|
6
|
+
export const defaultNS = 'common';
|
|
7
|
+
i18next.use(LanguageDetector).use(initReactI18next).init({
|
|
8
|
+
resources: undefined,
|
|
9
|
+
lng: useSettings.getState().language,
|
|
10
|
+
defaultNS,
|
|
11
|
+
fallbackLng: 'en',
|
|
12
|
+
});
|
|
13
|
+
export default i18next;
|
package/dist/index.css
ADDED
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
@tailwind base;
|
|
2
|
+
@tailwind components;
|
|
3
|
+
@tailwind utilities;
|
|
4
|
+
|
|
5
|
+
@layer base {
|
|
6
|
+
:root {
|
|
7
|
+
--background: 0 0% 100%;
|
|
8
|
+
--foreground: 240 10% 3.9%;
|
|
9
|
+
|
|
10
|
+
--card: 0 0% 100%;
|
|
11
|
+
--card-foreground: 240 10% 3.9%;
|
|
12
|
+
|
|
13
|
+
--popover: 0 0% 100%;
|
|
14
|
+
--popover-foreground: 240 10% 3.9%;
|
|
15
|
+
|
|
16
|
+
--primary: 240 5.9% 10%;
|
|
17
|
+
--primary-foreground: 0 0% 98%;
|
|
18
|
+
|
|
19
|
+
--secondary: 240 4.8% 95.9%;
|
|
20
|
+
--secondary-foreground: 240 5.9% 10%;
|
|
21
|
+
|
|
22
|
+
--muted: 240 4.8% 95.9%;
|
|
23
|
+
--muted-foreground: 240 3.8% 46.1%;
|
|
24
|
+
|
|
25
|
+
--accent: 240 4.8% 95.9%;
|
|
26
|
+
--accent-foreground: 240 5.9% 10%;
|
|
27
|
+
|
|
28
|
+
--destructive: 0 84.2% 60.2%;
|
|
29
|
+
--destructive-foreground: 0 0% 98%;
|
|
30
|
+
|
|
31
|
+
--border: 240 5.9% 90%;
|
|
32
|
+
--input: 240 5.9% 90%;
|
|
33
|
+
--ring: 240 10% 3.9%;
|
|
34
|
+
|
|
35
|
+
--radius: 0.5rem;
|
|
36
|
+
|
|
37
|
+
--warning: 38 92% 50%;
|
|
38
|
+
--warning-foreground: 48 96% 89%;
|
|
39
|
+
|
|
40
|
+
--navigation-link: 240 10% 3.9%;
|
|
41
|
+
|
|
42
|
+
--topbar-height: 70px;
|
|
43
|
+
--topbar-height-lg: 80px;
|
|
44
|
+
|
|
45
|
+
--page-padding-total-y: 2.75rem;
|
|
46
|
+
--page-padding-total-y-md: 4.75rem;
|
|
47
|
+
--page-padding-total-y-lg: 2rem;
|
|
48
|
+
|
|
49
|
+
--page-content-h: calc(100vh - var(--topbar-height) - var(--page-padding-total-y));
|
|
50
|
+
--page-content-h-md: calc(100vh - var(--topbar-height) - var(--page-padding-total-y-md));
|
|
51
|
+
--page-content-h-lg: calc(100vh - var(--topbar-height-lg) - var(--page-padding-total-y-lg));
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.dark {
|
|
55
|
+
--background: 240 10% 3.9%;
|
|
56
|
+
--foreground: 0 0% 98%;
|
|
57
|
+
|
|
58
|
+
--card: 240 10% 3.9%;
|
|
59
|
+
--card-foreground: 0 0% 98%;
|
|
60
|
+
|
|
61
|
+
--popover: 240 10% 3.9%;
|
|
62
|
+
--popover-foreground: 0 0% 98%;
|
|
63
|
+
|
|
64
|
+
--primary: 0 0% 98%;
|
|
65
|
+
--primary-foreground: 240 5.9% 10%;
|
|
66
|
+
|
|
67
|
+
--secondary: 240 3.7% 15.9%;
|
|
68
|
+
--secondary-foreground: 0 0% 98%;
|
|
69
|
+
|
|
70
|
+
--muted: 240 3.7% 15.9%;
|
|
71
|
+
--muted-foreground: 240 5% 64.9%;
|
|
72
|
+
|
|
73
|
+
--accent: 240 3.7% 15.9%;
|
|
74
|
+
--accent-foreground: 0 0% 98%;
|
|
75
|
+
|
|
76
|
+
--destructive: 0 62.8% 30.6%;
|
|
77
|
+
--destructive-foreground: 0 0% 98%;
|
|
78
|
+
|
|
79
|
+
--border: 240 3.7% 15.9%;
|
|
80
|
+
--input: 240 3.7% 15.9%;
|
|
81
|
+
--ring: 240 4.9% 83.9%;
|
|
82
|
+
|
|
83
|
+
--warning: 48 96% 89%;
|
|
84
|
+
--warning-foreground: 38 92% 50%;
|
|
85
|
+
|
|
86
|
+
--navigation-link: 0 0% 98%;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
@layer base {
|
|
90
|
+
* {
|
|
91
|
+
@apply border-border;
|
|
92
|
+
}
|
|
93
|
+
body {
|
|
94
|
+
@apply bg-background text-foreground box-border;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
@layer utilities {
|
|
99
|
+
.min-h-screen {
|
|
100
|
+
min-height: 100vh; /* Fallback */
|
|
101
|
+
min-height: 100dvh;
|
|
102
|
+
}
|
|
103
|
+
.h-screen {
|
|
104
|
+
height: 100vh; /* Fallback */
|
|
105
|
+
height: 100dvh;
|
|
106
|
+
}
|
|
107
|
+
.page-content-h {
|
|
108
|
+
@apply h-[var(--page-content-h)] max-h-[var(--page-content-h)] md:h-[var(--page-content-h-md)] md:max-h-[var(--page-content-h-md)] lg:h-[var(--page-content-h-lg)] lg:max-h-[var(--page-content-h-lg)];
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
*::-webkit-scrollbar {
|
|
113
|
+
width: 6px;
|
|
114
|
+
transform: translateX(-4px);
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
*::-webkit-scrollbar-thumb {
|
|
118
|
+
@apply bg-border relative rounded-full;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
*::-webkit-scrollbar-track {
|
|
122
|
+
@apply flex touch-none select-none transition-colors;
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
input:-webkit-autofill,
|
|
126
|
+
input:-webkit-autofill:focus {
|
|
127
|
+
transition:
|
|
128
|
+
background-color 0s 600000s,
|
|
129
|
+
color 0s 600000s !important;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
a {
|
|
133
|
+
display: contents;
|
|
134
|
+
text-decoration: none;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.Puck > div:nth-child(1) {
|
|
138
|
+
position: relative !important;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
@layer components {
|
|
142
|
+
.customSpinner {
|
|
143
|
+
width: 48px;
|
|
144
|
+
height: 48px;
|
|
145
|
+
border: 5px solid hsl(var(--primary));
|
|
146
|
+
border-bottom-color: transparent;
|
|
147
|
+
border-radius: 50%;
|
|
148
|
+
display: inline-block;
|
|
149
|
+
box-sizing: border-box;
|
|
150
|
+
animation: rotation 1s linear infinite;
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
@keyframes rotation {
|
|
154
|
+
0% {
|
|
155
|
+
transform: rotate(0deg);
|
|
156
|
+
}
|
|
157
|
+
100% {
|
|
158
|
+
transform: rotate(360deg);
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { DeenruvUIPlugin, DeenruvAdminPanelSettings } from '@deenruv/react-ui-devkit';
|
|
2
|
+
|
|
3
|
+
export function DeenruvAdminPanel({
|
|
4
|
+
plugins,
|
|
5
|
+
settings,
|
|
6
|
+
}: {
|
|
7
|
+
plugins: Array<DeenruvUIPlugin>;
|
|
8
|
+
settings: DeenruvAdminPanelSettings;
|
|
9
|
+
}): JSX.Element;
|
|
10
|
+
|
|
11
|
+
export type { DeenruvAdminPanelSettings, DeenruvUIPlugin };
|
package/dist/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './DeenruvAdminPanel';
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
{
|
|
2
|
+
"create": "Create administrator",
|
|
3
|
+
"edit": "Edit administrator",
|
|
4
|
+
"baseInfoCode": "Code: {{value}}",
|
|
5
|
+
"baseInfoId": "Id: {{value}}",
|
|
6
|
+
"baseInfoCreated": "Created: {{value}}",
|
|
7
|
+
"baseInfoUpdated": "Updated: {{value}}",
|
|
8
|
+
"buttonDisabledTooltip": "Fill in all required fields",
|
|
9
|
+
"noChangesTooltip": "No changes have been made",
|
|
10
|
+
"table": {
|
|
11
|
+
"id": "Id",
|
|
12
|
+
"name": "Name",
|
|
13
|
+
"emailAddress": "Email",
|
|
14
|
+
"role": "Role",
|
|
15
|
+
"createdAt": "Established in",
|
|
16
|
+
"updatedAt": "Updated by",
|
|
17
|
+
"openMenu": "Open menu",
|
|
18
|
+
"copyId": "Copy identifier",
|
|
19
|
+
"viewAdmin": "Display admin",
|
|
20
|
+
"columns": "Columns"
|
|
21
|
+
},
|
|
22
|
+
"details": {
|
|
23
|
+
"basic": {
|
|
24
|
+
"title": "Basic information",
|
|
25
|
+
"firstName": "Name",
|
|
26
|
+
"lastName": "Surname",
|
|
27
|
+
"emailAddress": "E-mail address",
|
|
28
|
+
"password": "Password"
|
|
29
|
+
},
|
|
30
|
+
"roles": {
|
|
31
|
+
"title": "Roles",
|
|
32
|
+
"placeholder": "Adding roles to a user"
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
"toasts": {
|
|
36
|
+
"adminLoadingError": "Failed to load administrator with ID {{value}}",
|
|
37
|
+
"adminUpdateSuccess": "Administrator successfully updated",
|
|
38
|
+
"adminUpdateError": "An error occurred:",
|
|
39
|
+
"adminCreatedSuccess": "Administrator has been successfully created",
|
|
40
|
+
"adminCreatedError": "Administrator could not be created",
|
|
41
|
+
"adminDeleteSuccess": "Administrator was successfully deleted",
|
|
42
|
+
"adminDeleteError": "Administrator could not be removed successfully"
|
|
43
|
+
},
|
|
44
|
+
"deleteAdmin": {
|
|
45
|
+
"title": "Remove administrator",
|
|
46
|
+
"description": "Are you sure you want to delete this administrator?",
|
|
47
|
+
"successMessage": "The administrator has been removed.",
|
|
48
|
+
"deleteOrCancel": "Delete/Cancel option selected"
|
|
49
|
+
},
|
|
50
|
+
"selectedValue": "{{from}} of {{to}} lines selected",
|
|
51
|
+
"validation": {
|
|
52
|
+
"firstNameRequired": "First name is required",
|
|
53
|
+
"lastNameRequired": "Last name is required",
|
|
54
|
+
"passwordRequired": "Password required",
|
|
55
|
+
"rolesRequired": "Select at least one role"
|
|
56
|
+
}
|
|
57
|
+
}
|