@shipstatic/types 0.8.7 → 0.8.9
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.d.ts +21 -0
- package/dist/index.js +14 -0
- package/package.json +1 -1
- package/src/index.ts +27 -1
package/dist/index.d.ts
CHANGED
|
@@ -585,6 +585,16 @@ export interface DeploymentUploadOptions {
|
|
|
585
585
|
labels?: string[];
|
|
586
586
|
/** Client identifier (e.g., 'cli', 'sdk', 'web') */
|
|
587
587
|
via?: string;
|
|
588
|
+
/**
|
|
589
|
+
* Optional password that protects this deployment.
|
|
590
|
+
*
|
|
591
|
+
* Length: {@link PASSWORD_CONSTRAINTS.MIN_LENGTH} to
|
|
592
|
+
* {@link PASSWORD_CONSTRAINTS.MAX_LENGTH} characters; whitespace is
|
|
593
|
+
* significant. Visitors are prompted to enter the password before they can
|
|
594
|
+
* view the deployment — including on any custom domains pointing at it.
|
|
595
|
+
* To remove protection, redeploy without a password.
|
|
596
|
+
*/
|
|
597
|
+
password?: string;
|
|
588
598
|
/** @internal Trigger server-side build. Only available via /upload endpoint. */
|
|
589
599
|
build?: boolean;
|
|
590
600
|
/** @internal Trigger server-side prerender. Only available via /upload endpoint. */
|
|
@@ -912,3 +922,14 @@ export declare function serializeLabels(labels: string[] | undefined): string |
|
|
|
912
922
|
* @example deserializeLabels('') → []
|
|
913
923
|
*/
|
|
914
924
|
export declare function deserializeLabels(labelsJson: string | null): string[];
|
|
925
|
+
/**
|
|
926
|
+
* Length constraints for the optional deployment password
|
|
927
|
+
* (`DeploymentUploadOptions.password`). Single source of truth shared across
|
|
928
|
+
* platform consumers.
|
|
929
|
+
*/
|
|
930
|
+
export declare const PASSWORD_CONSTRAINTS: {
|
|
931
|
+
/** Minimum password length in characters */
|
|
932
|
+
readonly MIN_LENGTH: 6;
|
|
933
|
+
/** Maximum password length in characters */
|
|
934
|
+
readonly MAX_LENGTH: 128;
|
|
935
|
+
};
|
package/dist/index.js
CHANGED
|
@@ -512,3 +512,17 @@ export function deserializeLabels(labelsJson) {
|
|
|
512
512
|
return [];
|
|
513
513
|
}
|
|
514
514
|
}
|
|
515
|
+
// =============================================================================
|
|
516
|
+
// PASSWORD UTILITIES
|
|
517
|
+
// =============================================================================
|
|
518
|
+
/**
|
|
519
|
+
* Length constraints for the optional deployment password
|
|
520
|
+
* (`DeploymentUploadOptions.password`). Single source of truth shared across
|
|
521
|
+
* platform consumers.
|
|
522
|
+
*/
|
|
523
|
+
export const PASSWORD_CONSTRAINTS = {
|
|
524
|
+
/** Minimum password length in characters */
|
|
525
|
+
MIN_LENGTH: 6,
|
|
526
|
+
/** Maximum password length in characters */
|
|
527
|
+
MAX_LENGTH: 128,
|
|
528
|
+
};
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -888,6 +888,16 @@ export interface DeploymentUploadOptions {
|
|
|
888
888
|
labels?: string[];
|
|
889
889
|
/** Client identifier (e.g., 'cli', 'sdk', 'web') */
|
|
890
890
|
via?: string;
|
|
891
|
+
/**
|
|
892
|
+
* Optional password that protects this deployment.
|
|
893
|
+
*
|
|
894
|
+
* Length: {@link PASSWORD_CONSTRAINTS.MIN_LENGTH} to
|
|
895
|
+
* {@link PASSWORD_CONSTRAINTS.MAX_LENGTH} characters; whitespace is
|
|
896
|
+
* significant. Visitors are prompted to enter the password before they can
|
|
897
|
+
* view the deployment — including on any custom domains pointing at it.
|
|
898
|
+
* To remove protection, redeploy without a password.
|
|
899
|
+
*/
|
|
900
|
+
password?: string;
|
|
891
901
|
/** @internal Trigger server-side build. Only available via /upload endpoint. */
|
|
892
902
|
build?: boolean;
|
|
893
903
|
/** @internal Trigger server-side prerender. Only available via /upload endpoint. */
|
|
@@ -1351,4 +1361,20 @@ export function deserializeLabels(labelsJson: string | null): string[] {
|
|
|
1351
1361
|
} catch {
|
|
1352
1362
|
return [];
|
|
1353
1363
|
}
|
|
1354
|
-
}
|
|
1364
|
+
}
|
|
1365
|
+
|
|
1366
|
+
// =============================================================================
|
|
1367
|
+
// PASSWORD UTILITIES
|
|
1368
|
+
// =============================================================================
|
|
1369
|
+
|
|
1370
|
+
/**
|
|
1371
|
+
* Length constraints for the optional deployment password
|
|
1372
|
+
* (`DeploymentUploadOptions.password`). Single source of truth shared across
|
|
1373
|
+
* platform consumers.
|
|
1374
|
+
*/
|
|
1375
|
+
export const PASSWORD_CONSTRAINTS = {
|
|
1376
|
+
/** Minimum password length in characters */
|
|
1377
|
+
MIN_LENGTH: 6,
|
|
1378
|
+
/** Maximum password length in characters */
|
|
1379
|
+
MAX_LENGTH: 128,
|
|
1380
|
+
} as const;
|