@acmekit/dashboard 2.13.14 → 2.13.16

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,6 +1,6 @@
1
1
  import {
2
2
  getApiKeyTypeFromPathname
3
- } from "./chunk-G22WWLPG.mjs";
3
+ } from "./chunk-J6XIB6ZU.mjs";
4
4
  import {
5
5
  useCreateApiKey
6
6
  } from "./chunk-EFRMWHRX.mjs";
@@ -61,8 +61,8 @@ var ApiKeyCreateForm = ({ keyType }) => {
61
61
  onSuccess: ({ api_key }) => {
62
62
  toast.success(t("apiKeyManagement.create.successToast"));
63
63
  switch (keyType) {
64
- case "publishable" /* PUBLISHABLE */:
65
- handleSuccess(`/settings/publishable-api-keys/${api_key.id}`);
64
+ case "client" /* CLIENT */:
65
+ handleSuccess(`/settings/client-api-keys/${api_key.id}`);
66
66
  break;
67
67
  case "secret" /* SECRET */:
68
68
  setCreatedKey(api_key);
@@ -98,8 +98,8 @@ var ApiKeyCreateForm = ({ keyType }) => {
98
98
  /* @__PURE__ */ jsx(RouteFocusModal.Header, {}),
99
99
  /* @__PURE__ */ jsx(RouteFocusModal.Body, { className: "flex flex-1 flex-col overflow-hidden", children: /* @__PURE__ */ jsx("div", { className: "flex flex-1 flex-col items-center overflow-y-auto", children: /* @__PURE__ */ jsxs("div", { className: "flex w-full max-w-[720px] flex-col gap-y-8 px-2 py-16", children: [
100
100
  /* @__PURE__ */ jsxs("div", { children: [
101
- /* @__PURE__ */ jsx(RouteFocusModal.Title, { asChild: true, children: /* @__PURE__ */ jsx(Heading, { children: keyType === "publishable" /* PUBLISHABLE */ ? t("apiKeyManagement.create.createPublishableHeader") : t("apiKeyManagement.create.createSecretHeader") }) }),
102
- /* @__PURE__ */ jsx(RouteFocusModal.Description, { asChild: true, children: /* @__PURE__ */ jsx(Text, { size: "small", className: "text-ui-fg-subtle", children: keyType === "publishable" /* PUBLISHABLE */ ? t("apiKeyManagement.create.createPublishableHint") : t("apiKeyManagement.create.createSecretHint") }) })
101
+ /* @__PURE__ */ jsx(RouteFocusModal.Title, { asChild: true, children: /* @__PURE__ */ jsx(Heading, { children: keyType === "client" /* CLIENT */ ? t("apiKeyManagement.create.createClientHeader") : t("apiKeyManagement.create.createSecretHeader") }) }),
102
+ /* @__PURE__ */ jsx(RouteFocusModal.Description, { asChild: true, children: /* @__PURE__ */ jsx(Text, { size: "small", className: "text-ui-fg-subtle", children: keyType === "client" /* CLIENT */ ? t("apiKeyManagement.create.createClientHint") : t("apiKeyManagement.create.createSecretHint") }) })
103
103
  ] }),
104
104
  /* @__PURE__ */ jsx("div", { className: "grid grid-cols-2 gap-4", children: /* @__PURE__ */ jsx(
105
105
  Form.Field,
@@ -2,7 +2,7 @@ import {
2
2
  getApiKeyStatusProps,
3
3
  getApiKeyTypeProps,
4
4
  prettifyRedactedToken
5
- } from "./chunk-G22WWLPG.mjs";
5
+ } from "./chunk-J6XIB6ZU.mjs";
6
6
  import {
7
7
  useDate
8
8
  } from "./chunk-DFFLVEZ5.mjs";
@@ -3,7 +3,7 @@ import {
3
3
  getApiKeyTypeFromPathname,
4
4
  getApiKeyTypeProps,
5
5
  prettifyRedactedToken
6
- } from "./chunk-G22WWLPG.mjs";
6
+ } from "./chunk-J6XIB6ZU.mjs";
7
7
  import {
8
8
  StatusCell
9
9
  } from "./chunk-WILMJYUB.mjs";
@@ -348,8 +348,8 @@ var ApiKeyManagementListTable = ({
348
348
  return /* @__PURE__ */ jsxs(Container, { className: "divide-y p-0", children: [
349
349
  /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between px-6 py-4", children: [
350
350
  /* @__PURE__ */ jsxs("div", { children: [
351
- /* @__PURE__ */ jsx6(Heading, { level: "h1", children: keyType === "publishable" ? t(`apiKeyManagement.domain.publishable`) : t("apiKeyManagement.domain.secret") }),
352
- /* @__PURE__ */ jsx6(Text, { className: "text-ui-fg-subtle", size: "small", children: keyType === "publishable" ? t(`apiKeyManagement.subtitle.publishable`) : t("apiKeyManagement.subtitle.secret") })
351
+ /* @__PURE__ */ jsx6(Heading, { level: "h1", children: keyType === "client" ? t(`apiKeyManagement.domain.client`) : t("apiKeyManagement.domain.secret") }),
352
+ /* @__PURE__ */ jsx6(Text, { className: "text-ui-fg-subtle", size: "small", children: keyType === "client" ? t(`apiKeyManagement.subtitle.client`) : t("apiKeyManagement.subtitle.secret") })
353
353
  ] }),
354
354
  /* @__PURE__ */ jsx6(Link, { to: "create", children: /* @__PURE__ */ jsx6(Button, { variant: "secondary", size: "small", children: t("actions.create") }) })
355
355
  ] }),
package/dist/app.js CHANGED
@@ -7205,7 +7205,7 @@ function getApiKeyTypeFromPathname(pathname) {
7205
7205
  case true:
7206
7206
  return "secret" /* SECRET */;
7207
7207
  case false:
7208
- return "publishable" /* PUBLISHABLE */;
7208
+ return "client" /* CLIENT */;
7209
7209
  }
7210
7210
  }
7211
7211
  function getApiKeyStatusProps(revokedAt, t3) {
@@ -7221,10 +7221,10 @@ function getApiKeyStatusProps(revokedAt, t3) {
7221
7221
  };
7222
7222
  }
7223
7223
  function getApiKeyTypeProps(type, t3) {
7224
- if (type === "publishable" /* PUBLISHABLE */) {
7224
+ if (type === "client" /* CLIENT */) {
7225
7225
  return {
7226
7226
  color: "green",
7227
- label: t3("apiKeyManagement.type.publishable")
7227
+ label: t3("apiKeyManagement.type.client")
7228
7228
  };
7229
7229
  }
7230
7230
  return {
@@ -7674,8 +7674,8 @@ var init_api_key_management_list_table = __esm({
7674
7674
  return /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)(import_ui58.Container, { className: "divide-y p-0", children: [
7675
7675
  /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("div", { className: "flex items-center justify-between px-6 py-4", children: [
7676
7676
  /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("div", { children: [
7677
- /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_ui58.Heading, { level: "h1", children: keyType === "publishable" ? t3(`apiKeyManagement.domain.publishable`) : t3("apiKeyManagement.domain.secret") }),
7678
- /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_ui58.Text, { className: "text-ui-fg-subtle", size: "small", children: keyType === "publishable" ? t3(`apiKeyManagement.subtitle.publishable`) : t3("apiKeyManagement.subtitle.secret") })
7677
+ /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_ui58.Heading, { level: "h1", children: keyType === "client" ? t3(`apiKeyManagement.domain.client`) : t3("apiKeyManagement.domain.secret") }),
7678
+ /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_ui58.Text, { className: "text-ui-fg-subtle", size: "small", children: keyType === "client" ? t3(`apiKeyManagement.subtitle.client`) : t3("apiKeyManagement.subtitle.secret") })
7679
7679
  ] }),
7680
7680
  /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_react_router_dom34.Link, { to: "create", children: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_ui58.Button, { variant: "secondary", size: "small", children: t3("actions.create") }) })
7681
7681
  ] }),
@@ -7804,8 +7804,8 @@ var init_api_key_create_form = __esm({
7804
7804
  onSuccess: ({ api_key }) => {
7805
7805
  import_ui59.toast.success(t3("apiKeyManagement.create.successToast"));
7806
7806
  switch (keyType) {
7807
- case "publishable" /* PUBLISHABLE */:
7808
- handleSuccess(`/settings/publishable-api-keys/${api_key.id}`);
7807
+ case "client" /* CLIENT */:
7808
+ handleSuccess(`/settings/client-api-keys/${api_key.id}`);
7809
7809
  break;
7810
7810
  case "secret" /* SECRET */:
7811
7811
  setCreatedKey(api_key);
@@ -7841,8 +7841,8 @@ var init_api_key_create_form = __esm({
7841
7841
  /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(RouteFocusModal.Header, {}),
7842
7842
  /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(RouteFocusModal.Body, { className: "flex flex-1 flex-col overflow-hidden", children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { className: "flex flex-1 flex-col items-center overflow-y-auto", children: /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)("div", { className: "flex w-full max-w-[720px] flex-col gap-y-8 px-2 py-16", children: [
7843
7843
  /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)("div", { children: [
7844
- /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(RouteFocusModal.Title, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(import_ui59.Heading, { children: keyType === "publishable" /* PUBLISHABLE */ ? t3("apiKeyManagement.create.createPublishableHeader") : t3("apiKeyManagement.create.createSecretHeader") }) }),
7845
- /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(RouteFocusModal.Description, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(import_ui59.Text, { size: "small", className: "text-ui-fg-subtle", children: keyType === "publishable" /* PUBLISHABLE */ ? t3("apiKeyManagement.create.createPublishableHint") : t3("apiKeyManagement.create.createSecretHint") }) })
7844
+ /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(RouteFocusModal.Title, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(import_ui59.Heading, { children: keyType === "client" /* CLIENT */ ? t3("apiKeyManagement.create.createClientHeader") : t3("apiKeyManagement.create.createSecretHeader") }) }),
7845
+ /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(RouteFocusModal.Description, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(import_ui59.Text, { size: "small", className: "text-ui-fg-subtle", children: keyType === "client" /* CLIENT */ ? t3("apiKeyManagement.create.createClientHint") : t3("apiKeyManagement.create.createSecretHint") }) })
7846
7846
  ] }),
7847
7847
  /* @__PURE__ */ (0, import_jsx_runtime79.jsx)("div", { className: "grid grid-cols-2 gap-4", children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(
7848
7848
  Form.Field,
@@ -26816,7 +26816,7 @@ var en_default = {
26816
26816
  productTag: "Product Tags",
26817
26817
  location: "Locations",
26818
26818
  shippingProfile: "Shipping Profiles",
26819
- publishableApiKey: "Publishable API Keys",
26819
+ clientApiKey: "Client API Keys",
26820
26820
  secretApiKey: "Secret API Keys",
26821
26821
  command: "Commands",
26822
26822
  navigation: "Navigation"
@@ -29386,11 +29386,11 @@ var en_default = {
29386
29386
  },
29387
29387
  apiKeyManagement: {
29388
29388
  domain: {
29389
- publishable: "Publishable API Keys",
29389
+ client: "Client API Keys",
29390
29390
  secret: "Secret API Keys"
29391
29391
  },
29392
29392
  subtitle: {
29393
- publishable: "Manage API keys used in the storefront to limit the scope of requests to specific sales channels.",
29393
+ client: "Manage API keys for client and public API access.",
29394
29394
  secret: "Manage API keys used to authenticate admin users in admin applications."
29395
29395
  },
29396
29396
  status: {
@@ -29398,12 +29398,12 @@ var en_default = {
29398
29398
  revoked: "Revoked"
29399
29399
  },
29400
29400
  type: {
29401
- publishable: "Publishable",
29401
+ client: "Client",
29402
29402
  secret: "Secret"
29403
29403
  },
29404
29404
  create: {
29405
- createPublishableHeader: "Create Publishable API Key",
29406
- createPublishableHint: "Create a new publishable API key to limit the scope of requests to specific sales channels.",
29405
+ createClientHeader: "Create Client API Key",
29406
+ createClientHint: "Create a new client API key for public or client application API access.",
29407
29407
  createSecretHeader: "Create Secret API Key",
29408
29408
  createSecretHint: "Create a new secret API key to access the AcmeKit API as an authenticated admin user.",
29409
29409
  secretKeyCreatedHeader: "Secret Key Created",
@@ -110636,7 +110636,7 @@ var Thumbnail = ({ src, alt, size = "base" }) => {
110636
110636
  var SEARCH_AREAS = [
110637
110637
  "all",
110638
110638
  "user",
110639
- "publishableApiKey",
110639
+ "clientApiKey",
110640
110640
  "secretApiKey",
110641
110641
  "command",
110642
110642
  "navigation"
@@ -110805,7 +110805,7 @@ var useGlobalShortcuts = () => {
110805
110805
  },
110806
110806
  label: t3("app.keyboardShortcuts.settings.goToPublishableApiKeys"),
110807
110807
  type: "settingShortcut",
110808
- to: "/settings/publishable-api-keys"
110808
+ to: "/settings/client-api-keys"
110809
110809
  },
110810
110810
  {
110811
110811
  keys: {
@@ -112754,7 +112754,6 @@ var useSettingRoutes = () => {
112754
112754
  const { t: t3 } = (0, import_react_i18next10.useTranslation)();
112755
112755
  return (0, import_react27.useMemo)(
112756
112756
  () => [
112757
- { label: t3("store.domain"), to: "/settings/store" },
112758
112757
  { label: t3("users.domain"), to: "/settings/users" },
112759
112758
  ...isTranslationsEnabled ? [{ label: t3("translations.domain"), to: "/settings/translations" }] : []
112760
112759
  ],
@@ -112766,8 +112765,8 @@ var useDeveloperRoutes = () => {
112766
112765
  return (0, import_react27.useMemo)(
112767
112766
  () => [
112768
112767
  {
112769
- label: t3("apiKeyManagement.domain.publishable"),
112770
- to: "/settings/publishable-api-keys"
112768
+ label: t3("apiKeyManagement.domain.client"),
112769
+ to: "/settings/client-api-keys"
112771
112770
  },
112772
112771
  {
112773
112772
  label: t3("apiKeyManagement.domain.secret"),
@@ -113002,9 +113001,9 @@ var defaultSettingsRouteChildren = [
113002
113001
  ]
113003
113002
  },
113004
113003
  {
113005
- path: "publishable-api-keys",
113004
+ path: "client-api-keys",
113006
113005
  element: /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(import_react_router_dom54.Outlet, {}),
113007
- handle: { breadcrumb: () => (0, import_i18next4.t)("apiKeyManagement.domain.publishable") },
113006
+ handle: { breadcrumb: () => (0, import_i18next4.t)("apiKeyManagement.domain.client") },
113008
113007
  children: [
113009
113008
  {
113010
113009
  path: "",
package/dist/app.mjs CHANGED
@@ -9107,7 +9107,7 @@ var en_default = {
9107
9107
  productTag: "Product Tags",
9108
9108
  location: "Locations",
9109
9109
  shippingProfile: "Shipping Profiles",
9110
- publishableApiKey: "Publishable API Keys",
9110
+ clientApiKey: "Client API Keys",
9111
9111
  secretApiKey: "Secret API Keys",
9112
9112
  command: "Commands",
9113
9113
  navigation: "Navigation"
@@ -11677,11 +11677,11 @@ var en_default = {
11677
11677
  },
11678
11678
  apiKeyManagement: {
11679
11679
  domain: {
11680
- publishable: "Publishable API Keys",
11680
+ client: "Client API Keys",
11681
11681
  secret: "Secret API Keys"
11682
11682
  },
11683
11683
  subtitle: {
11684
- publishable: "Manage API keys used in the storefront to limit the scope of requests to specific sales channels.",
11684
+ client: "Manage API keys for client and public API access.",
11685
11685
  secret: "Manage API keys used to authenticate admin users in admin applications."
11686
11686
  },
11687
11687
  status: {
@@ -11689,12 +11689,12 @@ var en_default = {
11689
11689
  revoked: "Revoked"
11690
11690
  },
11691
11691
  type: {
11692
- publishable: "Publishable",
11692
+ client: "Client",
11693
11693
  secret: "Secret"
11694
11694
  },
11695
11695
  create: {
11696
- createPublishableHeader: "Create Publishable API Key",
11697
- createPublishableHint: "Create a new publishable API key to limit the scope of requests to specific sales channels.",
11696
+ createClientHeader: "Create Client API Key",
11697
+ createClientHint: "Create a new client API key for public or client application API access.",
11698
11698
  createSecretHeader: "Create Secret API Key",
11699
11699
  createSecretHint: "Create a new secret API key to access the AcmeKit API as an authenticated admin user.",
11700
11700
  secretKeyCreatedHeader: "Secret Key Created",
@@ -92949,7 +92949,7 @@ var Thumbnail = ({ src, alt, size = "base" }) => {
92949
92949
  var SEARCH_AREAS = [
92950
92950
  "all",
92951
92951
  "user",
92952
- "publishableApiKey",
92952
+ "clientApiKey",
92953
92953
  "secretApiKey",
92954
92954
  "command",
92955
92955
  "navigation"
@@ -93116,7 +93116,7 @@ var useGlobalShortcuts = () => {
93116
93116
  },
93117
93117
  label: t2("app.keyboardShortcuts.settings.goToPublishableApiKeys"),
93118
93118
  type: "settingShortcut",
93119
- to: "/settings/publishable-api-keys"
93119
+ to: "/settings/client-api-keys"
93120
93120
  },
93121
93121
  {
93122
93122
  keys: {
@@ -95089,7 +95089,6 @@ var useSettingRoutes = () => {
95089
95089
  const { t: t2 } = useTranslation9();
95090
95090
  return useMemo5(
95091
95091
  () => [
95092
- { label: t2("store.domain"), to: "/settings/store" },
95093
95092
  { label: t2("users.domain"), to: "/settings/users" },
95094
95093
  ...isTranslationsEnabled ? [{ label: t2("translations.domain"), to: "/settings/translations" }] : []
95095
95094
  ],
@@ -95101,8 +95100,8 @@ var useDeveloperRoutes = () => {
95101
95100
  return useMemo5(
95102
95101
  () => [
95103
95102
  {
95104
- label: t2("apiKeyManagement.domain.publishable"),
95105
- to: "/settings/publishable-api-keys"
95103
+ label: t2("apiKeyManagement.domain.client"),
95104
+ to: "/settings/client-api-keys"
95106
95105
  },
95107
95106
  {
95108
95107
  label: t2("apiKeyManagement.domain.secret"),
@@ -95336,9 +95335,9 @@ var defaultSettingsRouteChildren = [
95336
95335
  ]
95337
95336
  },
95338
95337
  {
95339
- path: "publishable-api-keys",
95338
+ path: "client-api-keys",
95340
95339
  element: /* @__PURE__ */ jsx21(Outlet4, {}),
95341
- handle: { breadcrumb: () => t("apiKeyManagement.domain.publishable") },
95340
+ handle: { breadcrumb: () => t("apiKeyManagement.domain.client") },
95342
95341
  children: [
95343
95342
  {
95344
95343
  path: "",
@@ -95346,11 +95345,11 @@ var defaultSettingsRouteChildren = [
95346
95345
  children: [
95347
95346
  {
95348
95347
  path: "",
95349
- lazy: () => import("./api-key-management-list-K2XPKF5E.mjs"),
95348
+ lazy: () => import("./api-key-management-list-HYZG23AG.mjs"),
95350
95349
  children: [
95351
95350
  {
95352
95351
  path: "create",
95353
- lazy: () => import("./api-key-management-create-VWUERPPB.mjs")
95352
+ lazy: () => import("./api-key-management-create-4AG76FJV.mjs")
95354
95353
  }
95355
95354
  ]
95356
95355
  }
@@ -95359,7 +95358,7 @@ var defaultSettingsRouteChildren = [
95359
95358
  {
95360
95359
  path: ":id",
95361
95360
  lazy: async () => {
95362
- const { Component, Breadcrumb, loader } = await import("./api-key-management-detail-V4ENQHYY.mjs");
95361
+ const { Component, Breadcrumb, loader } = await import("./api-key-management-detail-T2TB4KST.mjs");
95363
95362
  return {
95364
95363
  Component,
95365
95364
  loader,
@@ -95388,11 +95387,11 @@ var defaultSettingsRouteChildren = [
95388
95387
  children: [
95389
95388
  {
95390
95389
  path: "",
95391
- lazy: () => import("./api-key-management-list-K2XPKF5E.mjs"),
95390
+ lazy: () => import("./api-key-management-list-HYZG23AG.mjs"),
95392
95391
  children: [
95393
95392
  {
95394
95393
  path: "create",
95395
- lazy: () => import("./api-key-management-create-VWUERPPB.mjs")
95394
+ lazy: () => import("./api-key-management-create-4AG76FJV.mjs")
95396
95395
  }
95397
95396
  ]
95398
95397
  }
@@ -95401,7 +95400,7 @@ var defaultSettingsRouteChildren = [
95401
95400
  {
95402
95401
  path: ":id",
95403
95402
  lazy: async () => {
95404
- const { Component, Breadcrumb, loader } = await import("./api-key-management-detail-V4ENQHYY.mjs");
95403
+ const { Component, Breadcrumb, loader } = await import("./api-key-management-detail-T2TB4KST.mjs");
95405
95404
  return {
95406
95405
  Component,
95407
95406
  loader,
@@ -5,7 +5,7 @@ function getApiKeyTypeFromPathname(pathname) {
5
5
  case true:
6
6
  return "secret" /* SECRET */;
7
7
  case false:
8
- return "publishable" /* PUBLISHABLE */;
8
+ return "client" /* CLIENT */;
9
9
  }
10
10
  }
11
11
  function getApiKeyStatusProps(revokedAt, t) {
@@ -21,10 +21,10 @@ function getApiKeyStatusProps(revokedAt, t) {
21
21
  };
22
22
  }
23
23
  function getApiKeyTypeProps(type, t) {
24
- if (type === "publishable" /* PUBLISHABLE */) {
24
+ if (type === "client" /* CLIENT */) {
25
25
  return {
26
26
  color: "green",
27
- label: t("apiKeyManagement.type.publishable")
27
+ label: t("apiKeyManagement.type.client")
28
28
  };
29
29
  }
30
30
  return {
package/dist/en.json CHANGED
@@ -191,7 +191,7 @@
191
191
  "productTag": "Product Tags",
192
192
  "location": "Locations",
193
193
  "shippingProfile": "Shipping Profiles",
194
- "publishableApiKey": "Publishable API Keys",
194
+ "clientApiKey": "Client API Keys",
195
195
  "secretApiKey": "Secret API Keys",
196
196
  "command": "Commands",
197
197
  "navigation": "Navigation"
@@ -2761,11 +2761,11 @@
2761
2761
  },
2762
2762
  "apiKeyManagement": {
2763
2763
  "domain": {
2764
- "publishable": "Publishable API Keys",
2764
+ "client": "Client API Keys",
2765
2765
  "secret": "Secret API Keys"
2766
2766
  },
2767
2767
  "subtitle": {
2768
- "publishable": "Manage API keys used in the storefront to limit the scope of requests to specific sales channels.",
2768
+ "client": "Manage API keys for client and public API access.",
2769
2769
  "secret": "Manage API keys used to authenticate admin users in admin applications."
2770
2770
  },
2771
2771
  "status": {
@@ -2773,12 +2773,12 @@
2773
2773
  "revoked": "Revoked"
2774
2774
  },
2775
2775
  "type": {
2776
- "publishable": "Publishable",
2776
+ "client": "Client",
2777
2777
  "secret": "Secret"
2778
2778
  },
2779
2779
  "create": {
2780
- "createPublishableHeader": "Create Publishable API Key",
2781
- "createPublishableHint": "Create a new publishable API key to limit the scope of requests to specific sales channels.",
2780
+ "createClientHeader": "Create Client API Key",
2781
+ "createClientHint": "Create a new client API key for public or client application API access.",
2782
2782
  "createSecretHeader": "Create Secret API Key",
2783
2783
  "createSecretHint": "Create a new secret API key to access the AcmeKit API as an authenticated admin user.",
2784
2784
  "secretKeyCreatedHeader": "Secret Key Created",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@acmekit/dashboard",
3
- "version": "2.13.14",
3
+ "version": "2.13.16",
4
4
  "scripts": {
5
5
  "generate:static": "node ./scripts/generate-currencies.js && prettier --write ./src/lib/currencies.ts",
6
6
  "dev": "../../../node_modules/.bin/vite",
@@ -39,10 +39,10 @@
39
39
  "dist"
40
40
  ],
41
41
  "dependencies": {
42
- "@acmekit/admin-shared": "2.13.11",
43
- "@acmekit/icons": "2.13.11",
44
- "@acmekit/js-sdk": "2.13.11",
45
- "@acmekit/ui": "4.1.11",
42
+ "@acmekit/admin-shared": "2.13.16",
43
+ "@acmekit/icons": "2.13.16",
44
+ "@acmekit/js-sdk": "2.13.16",
45
+ "@acmekit/ui": "4.1.12",
46
46
  "@ariakit/react": "^0.4.15",
47
47
  "@babel/runtime": "^7.26.10",
48
48
  "@dnd-kit/core": "^6.1.0",
@@ -80,10 +80,10 @@
80
80
  "zod": "3.25.76"
81
81
  },
82
82
  "devDependencies": {
83
- "@acmekit/admin-shared": "2.13.11",
84
- "@acmekit/admin-vite-plugin": "2.13.11",
85
- "@acmekit/types": "2.13.11",
86
- "@acmekit/ui-preset": "2.13.11"
83
+ "@acmekit/admin-shared": "2.13.16",
84
+ "@acmekit/admin-vite-plugin": "2.13.16",
85
+ "@acmekit/types": "2.13.16",
86
+ "@acmekit/ui-preset": "2.13.16"
87
87
  },
88
88
  "packageManager": "yarn@3.2.1"
89
89
  }
@@ -25,7 +25,6 @@ const useSettingRoutes = (): INavItem[] => {
25
25
 
26
26
  return useMemo(
27
27
  () => [
28
- { label: t("store.domain"), to: "/settings/store" },
29
28
  { label: t("users.domain"), to: "/settings/users" },
30
29
  ...(isTranslationsEnabled
31
30
  ? [{ label: t("translations.domain"), to: "/settings/translations" }]
@@ -40,8 +39,8 @@ const useDeveloperRoutes = (): INavItem[] => {
40
39
  return useMemo(
41
40
  () => [
42
41
  {
43
- label: t("apiKeyManagement.domain.publishable"),
44
- to: "/settings/publishable-api-keys",
42
+ label: t("apiKeyManagement.domain.client"),
43
+ to: "/settings/client-api-keys",
45
44
  },
46
45
  {
47
46
  label: t("apiKeyManagement.domain.secret"),
@@ -1,7 +1,7 @@
1
1
  export const SEARCH_AREAS = [
2
2
  "all",
3
3
  "user",
4
- "publishableApiKey",
4
+ "clientApiKey",
5
5
  "secretApiKey",
6
6
  "command",
7
7
  "navigation",
@@ -75,9 +75,9 @@ const defaultSettingsRouteChildren: RouteObject[] = [
75
75
  ],
76
76
  },
77
77
  {
78
- path: "publishable-api-keys",
78
+ path: "client-api-keys",
79
79
  element: <Outlet />,
80
- handle: { breadcrumb: () => t("apiKeyManagement.domain.publishable") },
80
+ handle: { breadcrumb: () => t("apiKeyManagement.domain.client") },
81
81
  children: [
82
82
  {
83
83
  path: "",
@@ -711,7 +711,7 @@
711
711
  "shippingProfile": {
712
712
  "type": "string"
713
713
  },
714
- "publishableApiKey": {
714
+ "clientApiKey": {
715
715
  "type": "string"
716
716
  },
717
717
  "secretApiKey": {
@@ -747,7 +747,7 @@
747
747
  "productTag",
748
748
  "location",
749
749
  "shippingProfile",
750
- "publishableApiKey",
750
+ "clientApiKey",
751
751
  "secretApiKey",
752
752
  "command",
753
753
  "navigation"
@@ -10284,27 +10284,27 @@
10284
10284
  "domain": {
10285
10285
  "type": "object",
10286
10286
  "properties": {
10287
- "publishable": {
10287
+ "client": {
10288
10288
  "type": "string"
10289
10289
  },
10290
10290
  "secret": {
10291
10291
  "type": "string"
10292
10292
  }
10293
10293
  },
10294
- "required": ["publishable", "secret"],
10294
+ "required": ["client", "secret"],
10295
10295
  "additionalProperties": false
10296
10296
  },
10297
10297
  "subtitle": {
10298
10298
  "type": "object",
10299
10299
  "properties": {
10300
- "publishable": {
10300
+ "client": {
10301
10301
  "type": "string"
10302
10302
  },
10303
10303
  "secret": {
10304
10304
  "type": "string"
10305
10305
  }
10306
10306
  },
10307
- "required": ["publishable", "secret"],
10307
+ "required": ["client", "secret"],
10308
10308
  "additionalProperties": false
10309
10309
  },
10310
10310
  "status": {
@@ -10323,23 +10323,23 @@
10323
10323
  "type": {
10324
10324
  "type": "object",
10325
10325
  "properties": {
10326
- "publishable": {
10326
+ "client": {
10327
10327
  "type": "string"
10328
10328
  },
10329
10329
  "secret": {
10330
10330
  "type": "string"
10331
10331
  }
10332
10332
  },
10333
- "required": ["publishable", "secret"],
10333
+ "required": ["client", "secret"],
10334
10334
  "additionalProperties": false
10335
10335
  },
10336
10336
  "create": {
10337
10337
  "type": "object",
10338
10338
  "properties": {
10339
- "createPublishableHeader": {
10339
+ "createClientHeader": {
10340
10340
  "type": "string"
10341
10341
  },
10342
- "createPublishableHint": {
10342
+ "createClientHint": {
10343
10343
  "type": "string"
10344
10344
  },
10345
10345
  "createSecretHeader": {
@@ -10365,8 +10365,8 @@
10365
10365
  }
10366
10366
  },
10367
10367
  "required": [
10368
- "createPublishableHeader",
10369
- "createPublishableHint",
10368
+ "createClientHeader",
10369
+ "createClientHint",
10370
10370
  "createSecretHeader",
10371
10371
  "createSecretHint",
10372
10372
  "secretKeyCreatedHeader",
@@ -191,7 +191,7 @@
191
191
  "productTag": "Product Tags",
192
192
  "location": "Locations",
193
193
  "shippingProfile": "Shipping Profiles",
194
- "publishableApiKey": "Publishable API Keys",
194
+ "clientApiKey": "Client API Keys",
195
195
  "secretApiKey": "Secret API Keys",
196
196
  "command": "Commands",
197
197
  "navigation": "Navigation"
@@ -2761,11 +2761,11 @@
2761
2761
  },
2762
2762
  "apiKeyManagement": {
2763
2763
  "domain": {
2764
- "publishable": "Publishable API Keys",
2764
+ "client": "Client API Keys",
2765
2765
  "secret": "Secret API Keys"
2766
2766
  },
2767
2767
  "subtitle": {
2768
- "publishable": "Manage API keys used in the storefront to limit the scope of requests to specific sales channels.",
2768
+ "client": "Manage API keys for client and public API access.",
2769
2769
  "secret": "Manage API keys used to authenticate admin users in admin applications."
2770
2770
  },
2771
2771
  "status": {
@@ -2773,12 +2773,12 @@
2773
2773
  "revoked": "Revoked"
2774
2774
  },
2775
2775
  "type": {
2776
- "publishable": "Publishable",
2776
+ "client": "Client",
2777
2777
  "secret": "Secret"
2778
2778
  },
2779
2779
  "create": {
2780
- "createPublishableHeader": "Create Publishable API Key",
2781
- "createPublishableHint": "Create a new publishable API key to limit the scope of requests to specific sales channels.",
2780
+ "createClientHeader": "Create Client API Key",
2781
+ "createClientHint": "Create a new client API key for public or client application API access.",
2782
2782
  "createSecretHeader": "Create Secret API Key",
2783
2783
  "createSecretHint": "Create a new secret API key to access the AcmeKit API as an authenticated admin user.",
2784
2784
  "secretKeyCreatedHeader": "Secret Key Created",
@@ -133,7 +133,7 @@ export const useGlobalShortcuts = () => {
133
133
  },
134
134
  label: t("app.keyboardShortcuts.settings.goToPublishableApiKeys"),
135
135
  type: "settingShortcut",
136
- to: "/settings/publishable-api-keys",
136
+ to: "/settings/client-api-keys",
137
137
  },
138
138
  {
139
139
  keys: {
@@ -63,8 +63,8 @@ export const ApiKeyCreateForm = ({ keyType }: ApiKeyCreateFormProps) => {
63
63
  toast.success(t("apiKeyManagement.create.successToast"))
64
64
 
65
65
  switch (keyType) {
66
- case ApiKeyType.PUBLISHABLE:
67
- handleSuccess(`/settings/publishable-api-keys/${api_key.id}`)
66
+ case ApiKeyType.CLIENT:
67
+ handleSuccess(`/settings/client-api-keys/${api_key.id}`)
68
68
  break
69
69
  case ApiKeyType.SECRET:
70
70
  setCreatedKey(api_key)
@@ -109,15 +109,15 @@ export const ApiKeyCreateForm = ({ keyType }: ApiKeyCreateFormProps) => {
109
109
  <div>
110
110
  <RouteFocusModal.Title asChild>
111
111
  <Heading>
112
- {keyType === ApiKeyType.PUBLISHABLE
113
- ? t("apiKeyManagement.create.createPublishableHeader")
112
+ {keyType === ApiKeyType.CLIENT
113
+ ? t("apiKeyManagement.create.createClientHeader")
114
114
  : t("apiKeyManagement.create.createSecretHeader")}
115
115
  </Heading>
116
116
  </RouteFocusModal.Title>
117
117
  <RouteFocusModal.Description asChild>
118
118
  <Text size="small" className="text-ui-fg-subtle">
119
- {keyType === ApiKeyType.PUBLISHABLE
120
- ? t("apiKeyManagement.create.createPublishableHint")
119
+ {keyType === ApiKeyType.CLIENT
120
+ ? t("apiKeyManagement.create.createClientHint")
121
121
  : t("apiKeyManagement.create.createSecretHint")}
122
122
  </Text>
123
123
  </RouteFocusModal.Description>
@@ -14,7 +14,7 @@ const PAGE_SIZE = 20
14
14
  export const ApiKeyManagementListTable = ({
15
15
  keyType,
16
16
  }: {
17
- keyType: "secret" | "publishable"
17
+ keyType: "secret" | "client"
18
18
  }) => {
19
19
  const { t } = useTranslation()
20
20
 
@@ -54,13 +54,13 @@ export const ApiKeyManagementListTable = ({
54
54
  <div className="flex items-center justify-between px-6 py-4">
55
55
  <div>
56
56
  <Heading level="h1">
57
- {keyType === "publishable"
58
- ? t(`apiKeyManagement.domain.publishable`)
57
+ {keyType === "client"
58
+ ? t(`apiKeyManagement.domain.client`)
59
59
  : t("apiKeyManagement.domain.secret")}
60
60
  </Heading>
61
61
  <Text className="text-ui-fg-subtle" size="small">
62
- {keyType === "publishable"
63
- ? t(`apiKeyManagement.subtitle.publishable`)
62
+ {keyType === "client"
63
+ ? t(`apiKeyManagement.subtitle.client`)
64
64
  : t("apiKeyManagement.subtitle.secret")}
65
65
  </Text>
66
66
  </div>
@@ -1,4 +1,4 @@
1
1
  export enum ApiKeyType {
2
2
  SECRET = "secret",
3
- PUBLISHABLE = "publishable",
3
+ CLIENT = "client",
4
4
  }
@@ -9,7 +9,7 @@ export function getApiKeyTypeFromPathname(pathname: string) {
9
9
  case true:
10
10
  return ApiKeyType.SECRET
11
11
  case false:
12
- return ApiKeyType.PUBLISHABLE
12
+ return ApiKeyType.CLIENT
13
13
  }
14
14
  }
15
15
 
@@ -34,10 +34,10 @@ export function getApiKeyTypeProps(
34
34
  type: AdminApiKeyResponse["api_key"]["type"],
35
35
  t: TFunction
36
36
  ): { color: "green" | "blue"; label: string } {
37
- if (type === ApiKeyType.PUBLISHABLE) {
37
+ if (type === ApiKeyType.CLIENT) {
38
38
  return {
39
39
  color: "green",
40
- label: t("apiKeyManagement.type.publishable"),
40
+ label: t("apiKeyManagement.type.client"),
41
41
  }
42
42
  }
43
43
 
@@ -1,75 +0,0 @@
1
- import {
2
- MutationOptions,
3
- QueryKey,
4
- UseQueryOptions,
5
- useMutation,
6
- useQuery,
7
- } from "@tanstack/react-query"
8
-
9
- import { FetchError } from "@acmekit/js-sdk"
10
- import { HttpTypes } from "@acmekit/types"
11
- import { sdk } from "../../lib/client"
12
- import { queryClient } from "../../lib/query-client"
13
- import { queryKeysFactory } from "../../lib/query-key-factory"
14
-
15
- const STORE_QUERY_KEY = "store" as const
16
- export const storeQueryKeys = queryKeysFactory(STORE_QUERY_KEY)
17
-
18
- /**
19
- * Workaround to keep the V1 version of retrieving the store.
20
- */
21
- export async function retrieveActiveStore(
22
- query?: HttpTypes.AdminStoreParams
23
- ): Promise<HttpTypes.AdminStoreResponse> {
24
- const response = await sdk.admin.store.list(query)
25
-
26
- const activeStore = response.stores?.[0]
27
-
28
- if (!activeStore) {
29
- throw new FetchError("No active store found", "Not Found", 404)
30
- }
31
-
32
- return { store: activeStore }
33
- }
34
-
35
- export const useStore = (
36
- query?: HttpTypes.SelectParams,
37
- options?: Omit<
38
- UseQueryOptions<
39
- HttpTypes.AdminStoreResponse,
40
- FetchError,
41
- HttpTypes.AdminStoreResponse,
42
- QueryKey
43
- >,
44
- "queryFn" | "queryKey"
45
- >
46
- ) => {
47
- const { data, ...rest } = useQuery({
48
- queryFn: () => retrieveActiveStore(query),
49
- queryKey: storeQueryKeys.details(),
50
- ...options,
51
- })
52
-
53
- return {
54
- ...data,
55
- ...rest,
56
- }
57
- }
58
-
59
- export const useUpdateStore = (
60
- id: string,
61
- options?: MutationOptions<
62
- HttpTypes.AdminStoreResponse,
63
- FetchError,
64
- HttpTypes.AdminUpdateStore
65
- >
66
- ) => {
67
- return useMutation({
68
- mutationFn: (payload) => sdk.admin.store.update(id, payload),
69
- onSuccess: (data, variables, context) => {
70
- queryClient.invalidateQueries({ queryKey: storeQueryKeys.details() })
71
- options?.onSuccess?.(data, variables, context)
72
- },
73
- ...options,
74
- })
75
- }