"use strict";
Object.defineProperty(exports, "__esModule", {
    value: true
});
function _export(target, all) {
    for(var name in all)Object.defineProperty(target, name, {
        enumerable: true,
        get: Object.getOwnPropertyDescriptor(all, name).get
    });
}
_export(exports, {
    get bambuSupportSchema () {
        return bambuSupportSchema;
    },
    get credentialCoreSettingUpdateSchema () {
        return credentialCoreSettingUpdateSchema;
    },
    get credentialSettingSchema () {
        return credentialSettingSchema;
    },
    get frontendSettingsUpdateSchema () {
        return frontendSettingsUpdateSchema;
    },
    get jwtSecretCredentialSettingUpdateSchema () {
        return jwtSecretCredentialSettingUpdateSchema;
    },
    get moonrakerSupportSchema () {
        return moonrakerSupportSchema;
    },
    get prusaLinkSupportSchema () {
        return prusaLinkSupportSchema;
    },
    get sentryDiagnosticsEnabledSchema () {
        return sentryDiagnosticsEnabledSchema;
    },
    get serverSettingsUpdateSchema () {
        return serverSettingsUpdateSchema;
    },
    get slicerApiKeyUpdateSchema () {
        return slicerApiKeyUpdateSchema;
    },
    get timeoutSettingsUpdateSchema () {
        return timeoutSettingsUpdateSchema;
    },
    get wizardUpdateSchema () {
        return wizardUpdateSchema;
    }
});
const _envutils = require("../../utils/env.utils");
const _zod = require("zod");
const serverSettingsUpdateSchema = _zod.z.object({
    registration: _zod.z.boolean(),
    loginRequired: _zod.z.boolean(),
    experimentalMoonrakerSupport: _zod.z.boolean(),
    experimentalBambuSupport: _zod.z.boolean(),
    experimentalPrusaLinkSupport: _zod.z.boolean(),
    sentryDiagnosticsEnabled: _zod.z.boolean()
});
const timeoutSettingsUpdateSchema = _zod.z.object({
    apiTimeout: _zod.z.number().int().min(1000),
    apiUploadTimeout: _zod.z.number().int().min(10000)
});
const frontendSettingsUpdateSchema = _zod.z.object({
    gridCols: _zod.z.number().int().min(1),
    gridRows: _zod.z.number().int().min(1),
    largeTiles: _zod.z.boolean(),
    tilePreferCancelOverQuickStop: _zod.z.boolean(),
    gridNameSortDirection: _zod.z.enum([
        'horizontal',
        'vertical'
    ]).optional()
});
const jwtSecretCredentialSettingUpdateSchema = _zod.z.object({
    jwtSecret: _zod.z.string().min(10)
});
const credentialSettingSchema = _zod.z.object({
    jwtExpiresIn: _zod.z.number().int().min((0, _envutils.isProductionEnvironment)() ? 120 : 0).max((0, _envutils.isProductionEnvironment)() ? 7200 : Infinity),
    refreshTokenAttempts: _zod.z.number().int().min(-1),
    refreshTokenExpiry: _zod.z.number().int().min((0, _envutils.isProductionEnvironment)() ? 240 : 0),
    slicerApiKey: _zod.z.string().nullable()
});
const credentialCoreSettingUpdateSchema = _zod.z.object({
    jwtExpiresIn: _zod.z.number().int().min((0, _envutils.isProductionEnvironment)() ? 120 : 0).max((0, _envutils.isProductionEnvironment)() ? 7200 : Infinity),
    refreshTokenAttempts: _zod.z.number().int().min(-1),
    refreshTokenExpiry: _zod.z.number().int().min((0, _envutils.isProductionEnvironment)() ? 240 : 0)
});
const slicerApiKeyUpdateSchema = _zod.z.object({
    slicerApiKey: _zod.z.string().nullable()
});
const wizardUpdateSchema = _zod.z.object({
    wizardCompleted: _zod.z.boolean(),
    wizardCompletedAt: _zod.z.date().nullable(),
    wizardVersion: _zod.z.number().int().min(0)
});
const sentryDiagnosticsEnabledSchema = _zod.z.object({
    enabled: _zod.z.boolean()
});
const moonrakerSupportSchema = _zod.z.object({
    enabled: _zod.z.boolean()
});
const prusaLinkSupportSchema = _zod.z.object({
    enabled: _zod.z.boolean()
});
const bambuSupportSchema = _zod.z.object({
    enabled: _zod.z.boolean()
});

//# sourceMappingURL=settings-service.validation.js.map