@orion-studios/payload-studio 0.6.0-beta.152 → 0.6.0-beta.154

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.
@@ -1396,7 +1396,27 @@ var decorateBuilderNumericSteppers = (root = document) => {
1396
1396
  return;
1397
1397
  }
1398
1398
  field.classList.add("has-orion-builder-stepper");
1399
+ input.type = "text";
1400
+ input.inputMode = "decimal";
1399
1401
  field.querySelector("select")?.setAttribute("tabindex", "-1");
1402
+ input.addEventListener(
1403
+ "keydown",
1404
+ (event) => {
1405
+ if (event.key !== "-" || event.metaKey || event.ctrlKey || event.altKey) {
1406
+ return;
1407
+ }
1408
+ event.preventDefault();
1409
+ event.stopPropagation();
1410
+ const selectionStart = input.selectionStart ?? 0;
1411
+ const selectionEnd = input.selectionEnd ?? selectionStart;
1412
+ const value = input.value || "";
1413
+ const nextValue = value.startsWith("-") && selectionStart === 0 && selectionEnd <= 1 ? value.slice(1) : `${value.slice(0, selectionStart)}-${value.slice(selectionEnd)}`;
1414
+ input.value = nextValue;
1415
+ const nextCursor = Math.min(selectionStart + 1, nextValue.length);
1416
+ input.setSelectionRange(nextCursor, nextCursor);
1417
+ },
1418
+ true
1419
+ );
1400
1420
  const stepper = document.createElement("span");
1401
1421
  stepper.className = "orion-builder-v2-stepper";
1402
1422
  stepper.addEventListener("pointerdown", (event) => {
@@ -1272,7 +1272,27 @@ var decorateBuilderNumericSteppers = (root = document) => {
1272
1272
  return;
1273
1273
  }
1274
1274
  field.classList.add("has-orion-builder-stepper");
1275
+ input.type = "text";
1276
+ input.inputMode = "decimal";
1275
1277
  field.querySelector("select")?.setAttribute("tabindex", "-1");
1278
+ input.addEventListener(
1279
+ "keydown",
1280
+ (event) => {
1281
+ if (event.key !== "-" || event.metaKey || event.ctrlKey || event.altKey) {
1282
+ return;
1283
+ }
1284
+ event.preventDefault();
1285
+ event.stopPropagation();
1286
+ const selectionStart = input.selectionStart ?? 0;
1287
+ const selectionEnd = input.selectionEnd ?? selectionStart;
1288
+ const value = input.value || "";
1289
+ const nextValue = value.startsWith("-") && selectionStart === 0 && selectionEnd <= 1 ? value.slice(1) : `${value.slice(0, selectionStart)}-${value.slice(selectionEnd)}`;
1290
+ input.value = nextValue;
1291
+ const nextCursor = Math.min(selectionStart + 1, nextValue.length);
1292
+ input.setSelectionRange(nextCursor, nextCursor);
1293
+ },
1294
+ true
1295
+ );
1276
1296
  const stepper = document.createElement("span");
1277
1297
  stepper.className = "orion-builder-v2-stepper";
1278
1298
  stepper.addEventListener("pointerdown", (event) => {
package/dist/index.mjs CHANGED
@@ -1,25 +1,25 @@
1
1
  import {
2
2
  admin_exports
3
3
  } from "./chunk-KHK6RTGC.mjs";
4
- import {
5
- nextjs_exports
6
- } from "./chunk-ZADL33R6.mjs";
7
- import "./chunk-ZTXJG4K5.mjs";
8
4
  import {
9
5
  blocks_exports
10
6
  } from "./chunk-JQAHXYAM.mjs";
11
7
  import {
12
- admin_app_exports
13
- } from "./chunk-RKTIFEUY.mjs";
14
- import "./chunk-W2UOCJDX.mjs";
8
+ nextjs_exports
9
+ } from "./chunk-ZADL33R6.mjs";
10
+ import "./chunk-ZTXJG4K5.mjs";
15
11
  import {
16
12
  studio_pages_exports
17
- } from "./chunk-276KAPGM.mjs";
18
- import "./chunk-7ZMXZRBP.mjs";
13
+ } from "./chunk-NGLIA2OE.mjs";
19
14
  import "./chunk-OQSEJXC4.mjs";
15
+ import "./chunk-7ZMXZRBP.mjs";
20
16
  import {
21
17
  studio_exports
22
18
  } from "./chunk-ADIIWIYL.mjs";
19
+ import {
20
+ admin_app_exports
21
+ } from "./chunk-RKTIFEUY.mjs";
22
+ import "./chunk-W2UOCJDX.mjs";
23
23
  import "./chunk-6BWS3CLP.mjs";
24
24
  export {
25
25
  admin_exports as admin,
@@ -7,14 +7,14 @@ import {
7
7
  pageStudioModuleManifest,
8
8
  resolveBuilderThemeTokens,
9
9
  toEditorInitialDoc
10
- } from "../chunk-276KAPGM.mjs";
10
+ } from "../chunk-NGLIA2OE.mjs";
11
+ import "../chunk-OQSEJXC4.mjs";
11
12
  import {
12
13
  createDefaultStudioDocument,
13
14
  defaultBuilderThemeTokens,
14
15
  layoutToStudioDocument,
15
16
  studioDocumentToLayout
16
17
  } from "../chunk-7ZMXZRBP.mjs";
17
- import "../chunk-OQSEJXC4.mjs";
18
18
  import "../chunk-ADIIWIYL.mjs";
19
19
  import "../chunk-6BWS3CLP.mjs";
20
20
  export {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@orion-studios/payload-studio",
3
- "version": "0.6.0-beta.152",
3
+ "version": "0.6.0-beta.154",
4
4
  "description": "Base CMS, builder, and custom admin toolkit for Orion Studios websites",
5
5
  "types": "./dist/index.d.ts",
6
6
  "main": "./dist/index.js",
@@ -1,3 +1,6 @@
1
+ import {
2
+ sectionStyleDefaults
3
+ } from "./chunk-OQSEJXC4.mjs";
1
4
  import {
2
5
  createDefaultStudioDocument,
3
6
  defaultBuilderThemeTokens,
@@ -5,9 +8,6 @@ import {
5
8
  migrateBlockToSettingsV2,
6
9
  studioDocumentToLayout
7
10
  } from "./chunk-7ZMXZRBP.mjs";
8
- import {
9
- sectionStyleDefaults
10
- } from "./chunk-OQSEJXC4.mjs";
11
11
  import {
12
12
  assertStudioDocumentV1,
13
13
  compileStudioDocument,