@camstack/types 1.2.389 → 1.2.390
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/addon.js +1 -8
- package/dist/addon.mjs +2 -2
- package/dist/capabilities/records.cap.d.ts +2 -8
- package/dist/capabilities/storage-admin.cap.d.ts +7 -50
- package/dist/generated/addon-api.d.ts +0 -21
- package/dist/generated/method-access-map.d.ts +1 -1
- package/dist/generated/method-device-selectors.d.ts +2 -2
- package/dist/index.js +22 -94
- package/dist/index.mjs +23 -88
- package/dist/records/entry-kind.d.ts +0 -1
- package/dist/records/errors.d.ts +1 -5
- package/dist/records/index.d.ts +0 -2
- package/dist/records/record-kind.d.ts +0 -1
- package/dist/records/records-access.d.ts +1 -6
- package/dist/{sleep-BSuCCFjf.mjs → sleep-CSuN0thG.mjs} +9 -60
- package/dist/{sleep-DKtoyk6X.js → sleep-gRQc2IoX.js} +8 -101
- package/package.json +1 -1
- package/dist/records/settings-array-adopts-from.d.ts +0 -12
- package/dist/records/settings-brokers-adopts-from.d.ts +0 -10
|
@@ -3226,7 +3226,6 @@ var RECORDS_ERROR_CODES = [
|
|
|
3226
3226
|
"secret-unavailable",
|
|
3227
3227
|
"invalid-record",
|
|
3228
3228
|
"declaration-refused",
|
|
3229
|
-
"adoption-pending",
|
|
3230
3229
|
"no-caller",
|
|
3231
3230
|
"batch-too-large"
|
|
3232
3231
|
];
|
|
@@ -3324,13 +3323,6 @@ var DeclarationRefusedError = class extends RecordsError {
|
|
|
3324
3323
|
this.name = "DeclarationRefusedError";
|
|
3325
3324
|
}
|
|
3326
3325
|
};
|
|
3327
|
-
/** A kind is empty while the legacy table it adopts from still holds rows. */
|
|
3328
|
-
var AdoptionPendingError = class extends RecordsError {
|
|
3329
|
-
constructor(detail) {
|
|
3330
|
-
super("adoption-pending", detail);
|
|
3331
|
-
this.name = "AdoptionPendingError";
|
|
3332
|
-
}
|
|
3333
|
-
};
|
|
3334
3326
|
var NoCallerError = class extends RecordsError {
|
|
3335
3327
|
constructor(detail) {
|
|
3336
3328
|
super("no-caller", detail);
|
|
@@ -3356,7 +3348,6 @@ var FACTORIES = {
|
|
|
3356
3348
|
"secret-unavailable": (d) => new RecordSecretUnavailableError(d),
|
|
3357
3349
|
"invalid-record": (d) => new InvalidRecordError(d),
|
|
3358
3350
|
"declaration-refused": (d) => new DeclarationRefusedError(d),
|
|
3359
|
-
"adoption-pending": (d) => new AdoptionPendingError(d),
|
|
3360
3351
|
"no-caller": (d) => new NoCallerError(d),
|
|
3361
3352
|
"batch-too-large": (d) => new BatchTooLargeError(d)
|
|
3362
3353
|
};
|
|
@@ -3668,7 +3659,13 @@ var RecordKindDeclarationSchema = z.object({
|
|
|
3668
3659
|
secretPaths: z.array(z.string().min(1)).default([]),
|
|
3669
3660
|
/** The id key of each array that carries a secret (`{ headers: 'name' }`). */
|
|
3670
3661
|
secretArrayKeys: z.record(z.string(), z.string()).default({}),
|
|
3671
|
-
/**
|
|
3662
|
+
/**
|
|
3663
|
+
* RETIRED (D900): the legacy table a kind adopted from during the records
|
|
3664
|
+
* migration. Nothing declares it any more and nothing reads it; the schema
|
|
3665
|
+
* still ACCEPTS it because the catalog rows the migration wrote carry it
|
|
3666
|
+
* (an orphaned kind is never redeclared) and an addon built before the
|
|
3667
|
+
* removal still sends it. Never set it.
|
|
3668
|
+
*/
|
|
3672
3669
|
adoptsFrom: z.string().min(1).optional(),
|
|
3673
3670
|
/** Kinds that must agree through `transact` sit in one file under one family name. */
|
|
3674
3671
|
transactFamily: z.string().min(1).optional(),
|
|
@@ -3743,7 +3740,6 @@ function defineRecordKinds(specs) {
|
|
|
3743
3740
|
maxDataBytes: spec.maxDataBytes,
|
|
3744
3741
|
secretPaths: [...secretPaths],
|
|
3745
3742
|
secretArrayKeys: spec.secretArrayKeys === void 0 ? void 0 : { ...spec.secretArrayKeys },
|
|
3746
|
-
adoptsFrom: spec.adoptsFrom,
|
|
3747
3743
|
transactFamily: spec.transactFamily,
|
|
3748
3744
|
entry: spec.entry === void 0 ? void 0 : {
|
|
3749
3745
|
title: spec.entry.title,
|
|
@@ -4084,10 +4080,7 @@ function createRecordsAccess(options) {
|
|
|
4084
4080
|
return delegate;
|
|
4085
4081
|
},
|
|
4086
4082
|
async declare(kinds) {
|
|
4087
|
-
|
|
4088
|
-
const pending = Object.entries(result.kinds).filter((entry) => entry[1].adoptionPending !== null);
|
|
4089
|
-
if (pending.length > 0) throw new AdoptionPendingError(`${pending.map(([name, r]) => r.adoptionPending === null ? name : `${name} (legacy table "${r.adoptionPending.legacyTable}" holds ${r.adoptionPending.legacyRows} rows)`).join(", ")}. Stop the addon and run scripts/hub/records-adopt.ts --copy --apply before starting this build`);
|
|
4090
|
-
return result.kinds;
|
|
4083
|
+
return (await call(() => options.transport.declareKinds({ kinds: { ...declarationsOf(kinds) } }))).kinds;
|
|
4091
4084
|
},
|
|
4092
4085
|
kind(definition) {
|
|
4093
4086
|
const existing = handles.get(definition);
|
|
@@ -4142,7 +4135,6 @@ function defineEntryKind(name, spec) {
|
|
|
4142
4135
|
...spec.database === void 0 ? {} : { database: spec.database },
|
|
4143
4136
|
...spec.indexes === void 0 ? {} : { indexes: spec.indexes },
|
|
4144
4137
|
...spec.secretArrayKeys === void 0 ? {} : { secretArrayKeys: spec.secretArrayKeys },
|
|
4145
|
-
...spec.adoptsFrom === void 0 ? {} : { adoptsFrom: spec.adoptsFrom },
|
|
4146
4138
|
entry: {
|
|
4147
4139
|
title: spec.title,
|
|
4148
4140
|
...spec.nameField === void 0 ? {} : { nameField: spec.nameField }
|
|
@@ -4152,49 +4144,6 @@ function defineEntryKind(name, spec) {
|
|
|
4152
4144
|
return defined;
|
|
4153
4145
|
}
|
|
4154
4146
|
//#endregion
|
|
4155
|
-
//#region src/records/settings-brokers-adopts-from.ts
|
|
4156
|
-
/**
|
|
4157
|
-
* Legacy source for broker entry adoption (B2): brokers live in addon-settings
|
|
4158
|
-
* as one row `<addonId>.brokers` whose value is an array until records-adopt
|
|
4159
|
-
* copies them into the entry kind.
|
|
4160
|
-
*/
|
|
4161
|
-
var SETTINGS_BROKERS_ADOPTS_PREFIX = "@settings-brokers/";
|
|
4162
|
-
/** The `adoptsFrom` value for an addon's broker entry kind. */
|
|
4163
|
-
function settingsBrokersAdoptsFrom(addonId) {
|
|
4164
|
-
return `${SETTINGS_BROKERS_ADOPTS_PREFIX}${addonId}`;
|
|
4165
|
-
}
|
|
4166
|
-
/** When non-null, `from` names an addon-settings brokers blob, not a SQL table. */
|
|
4167
|
-
function parseSettingsBrokersAdoptsFrom(from) {
|
|
4168
|
-
if (!from.startsWith("@settings-brokers/")) return null;
|
|
4169
|
-
const addonId = from.slice(18);
|
|
4170
|
-
return addonId.length > 0 ? addonId : null;
|
|
4171
|
-
}
|
|
4172
|
-
//#endregion
|
|
4173
|
-
//#region src/records/settings-array-adopts-from.ts
|
|
4174
|
-
/**
|
|
4175
|
-
* Legacy source for entry adoption (B3): a list stored under addon-settings
|
|
4176
|
-
* `<addonId>.<key>` until records-adopt copies rows into the entry kind.
|
|
4177
|
-
*/
|
|
4178
|
-
var SETTINGS_ARRAY_ADOPTS_PREFIX = "@settings-array/";
|
|
4179
|
-
/** The `adoptsFrom` value for an addon-settings array field. */
|
|
4180
|
-
function settingsArrayAdoptsFrom(addonId, settingsKey) {
|
|
4181
|
-
return `${SETTINGS_ARRAY_ADOPTS_PREFIX}${addonId}/${settingsKey}`;
|
|
4182
|
-
}
|
|
4183
|
-
/** When non-null, `from` names an addon-settings array blob, not a SQL table. */
|
|
4184
|
-
function parseSettingsArrayAdoptsFrom(from) {
|
|
4185
|
-
if (!from.startsWith("@settings-array/")) return null;
|
|
4186
|
-
const rest = from.slice(16);
|
|
4187
|
-
const slash = rest.indexOf("/");
|
|
4188
|
-
if (slash <= 0 || slash >= rest.length - 1) return null;
|
|
4189
|
-
const addonId = rest.slice(0, slash);
|
|
4190
|
-
const settingsKey = rest.slice(slash + 1);
|
|
4191
|
-
if (addonId.length === 0 || settingsKey.length === 0) return null;
|
|
4192
|
-
return {
|
|
4193
|
-
addonId,
|
|
4194
|
-
settingsKey
|
|
4195
|
-
};
|
|
4196
|
-
}
|
|
4197
|
-
//#endregion
|
|
4198
4147
|
//#region src/records/in-memory-records.ts
|
|
4199
4148
|
/**
|
|
4200
4149
|
* In-memory `RecordsAccess` for specs. Kinds are declared by the caller.
|
|
@@ -7555,4 +7504,4 @@ function sleepCancellable(ms, signal) {
|
|
|
7555
7504
|
});
|
|
7556
7505
|
}
|
|
7557
7506
|
//#endregion
|
|
7558
|
-
export { optionalMethod as $,
|
|
7507
|
+
export { optionalMethod as $, DisposerChain as $n, recordSecretRef as $t, HF_REPO as A, RECORD_MAX_INDEXES as An, dehydrateSchema as Ar, makeProfileBrokerId as At, describeCustomActions as B, clearKnownSecrets as Bn, toSecretFieldView as Br, RecordIndexSchema as Bt, addonSliceHandleApi as C, RECORD_BATCH_MAX_BYTES as Cn, emitReadiness as Cr, ProfileRtspEntrySchema as Ct, createSliceHandle as D, RECORD_DELETE_BATCH as Dn, collectHydratedFieldEntries as Dr, StreamSourceSchema as Dt, createMirrorSource as E, RECORD_DEFAULT_MAX_DATA_BYTES as En, WELL_KNOWN_TAB_MAP as Er, StreamSourceEntrySchema$1 as Et, DEVICE_CHILDREN_BATCH_MAX as F, RECORD_SWEEP_INTERVAL_MS as Fn, isSecretClear as Fr, defineEntryKind as Ft, DEVICE_STATUS_METHOD as G, shortSecretRefHash as Gn, isSecretConfigField as Gr, declarationsOf as Gt, adminUiCapability as H, knownSecretCount as Hn, collectKeychainStoredKeys as Hr, RecordKindNameSchema as Ht, CALLER_STAMPED_CAPABILITIES as I, resolveSecretViewsIn as In, isSecretFieldView as Ir, entryBody as It, PROVIDER_PIN_FIELD as J, PEER_BYTES_STALL_MS as Jn, AUDIO_CHUNK_FORMATS as Jr, collectSecretLeaves as Jt, HISTORY_DEFAULT_MIN_INTERVAL_MS as K, PEER_BYTES_CHUNK_BYTES as Kn, omitTransientConfig as Kr, defineRecordKinds as Kt, withoutCallerStamp as L, REVALIDATE_AFTER_MS as Ln, isSecretMarker as Lr, createRecordsAccess as Lt, RawStateResultSchema as M, RECORD_QUERY_MAX as Mn, resolveHydratedFieldValue as Mr, parseProfileBrokerId as Mt, deviceOpsCapability as N, RECORD_SECRET_COLLECTION_PREFIX as Nn, SECRET_CLEAR as Nr, selectAssignedProfileSlots as Nt, DEFAULT_TOKEN_EXPIRY as O, RECORD_ID_MAX_LENGTH as On, collectHydratedFieldValues as Or, SubscribeAudioChunksInputSchema as Ot, viewerUiCapability as P, RECORD_SETTINGS_MAX_ROWS as Pn, classifySecretWrite as Pr, makeInMemoryRecords as Pt, method as Q, SHARE_VIEW_KINDS as Qn, recordSecretCollection as Qt, customAction as R, createSecretsAccess as Rn, isSecretMarkerLike as Rr, EntryDescriptorSchema as Rt, invokeTrpcLeaf as S, RECORD_BATCH_MAX as Sn, createEvent as Sr, FrameHandleSchema as St, createLazyTrpcSource as T, RECORD_DATABASES as Tn, WELL_KNOWN_TABS as Tr, ProfileSlotStatusSchema as Tt, DEFAULT_RUNTIME_STATE_DURABILITY as U, registerKnownSecret as Un, collectSecretConfigKeys as Ur, RecordRetentionSchema as Ut, deviceCustomAction as V, forgetKnownSecret as Vn, REDACTED_SECRET as Vr, RecordKindDeclarationSchema as Vt, DEVICE_SETTINGS_CONTRIBUTION_METHODS as W, scrubKnownSecrets as Wn, isKeychainStoredField as Wr, assertValidDeclaration as Wt, expandCapMethods as X, PeerBytesTicketSchema as Xn, expandAudioChunkToF32le as Xr, parseSecretPath as Xt, event as Y, PEER_BYTES_TICKET_TTL_MS as Yn, audioChunkBytesPerSample as Yr, mapSecretLeaves as Yt, isDeviceConfigCap as Z, DATAPLANE_SECRET_HEADER as Zn, isAudioChunkFormat as Zr, recordArrayItemPath as Zt, readErrorI18n as _, RevConflictError as _n, isSecretRef as _r, CamProfileSchema as _t, asJsonArray as a, DeclarationRefusedError as an, secretTreeFromPaths as ar, toNodeId as at, isDeviceScopedCap as b, asRecordsError as bn, normalizeNodeId as br, CameraStreamSchema as bt, asString as c, InvalidRecordError as cn, collectSecretMarkerRefs as cr, ReadinessTimeoutError as ct, parseJsonUnknown as d, RECORDS_ERROR_CODES as dn, transformSecretWrite as dr, scopeKey as dt, secretArrayPrefixes as en, BaseAddon as er, resolveCapMount as et, hfModelUrl as f, RecordNotFoundError as fn, SECRET_REF_SCHEME as fr, AudioChunkFormatSchema as ft, ErrorI18nPayloadSchema as g, RecordsError as gn, globalSecretScope as gr, CAM_PROFILE_ORDER as gt, ErrorCodeSchema as h, RecordUniqueViolationError as hn, formatSecretScope as hr, BrokerStatusSchema as ht, asBoolean as i, BatchTooLargeError as in, parseSecretStatePath as ir, readNodePin as it, RUNTIME_DEFAULTS as j, RECORD_MAX_INDEX_FIELDS as jn, hydrateSchema as jr, makeSourceBrokerId as jt, HF_BASE_URL as k, RECORD_MAX_DATA_BYTES as kn, dehydrateConfigField as kr, SubscribeAudioChunksResultSchema as kt, parseJsonArray as l, NoCallerError as ln, isSecretRefOwnedBy as lr, emitDownForOwnedCaps as lt, CamstackError as m, RecordTooLargeError as mn, buildSecretRef as mr, BrokerStatsSchema as mt, sleepCancellable as n, collectZodSecretPaths as nn, normalizeAddonInitResult as nr, CAP_NODE_PIN_CONTEXT_KEY as nt, asJsonObject as o, FilterRequiredError as on, secretTreeFromSchema as or, MODEL_FORMATS as ot, BOOT_RECOVERY_BACKOFF_MS as p, RecordSecretUnavailableError as pn, arrayItemFieldPath as pr, AudioStreamPickSchema as pt, HISTORY_UNIT_LABELS as q, PEER_BYTES_MAX_OUTSTANDING as qn, schemaDeclaresAnyField as qr, REMOVE_LEAF as qt, maskUrlCredentials as r, isZodSecret as rn, mergeSecretStatePaths as rr, nodePin as rt, asNumber as s, ForeignSecretMarkerError as sn, KeychainWriteRefusedError as sr, ReadinessRegistry as st, sleep as t, SECRET_META as tn, classifyStoreError as tr, systemMethod as tt, parseJsonObject as u, PlaintextSecretError as un, resolveSecretMarkers as ur, readinessKey as ut, userError as v, UnindexedFilterError as vn, normalizeSecretOwner as vr, CamStreamKindSchema as vt, createEventBusSliceSource as w, RECORD_CLASSES as wn, isEvent as wr, ProfileSlotSchema as wt, createDeviceProxy as x, recordsErrorFromMessage as xn, createDurableState as xr, DecodedAudioChunkSchema as xt, DEVICE_SCOPED_CAPS as y, UnknownRecordKindError as yn, parseSecretRef as yr, CamStreamResolutionSchema as yt, defineCustomActions as z, MIN_SCRUBBED_LENGTH as zn, makeSecretMarker as zr, RecordFieldPathSchema as zt };
|
|
@@ -3226,7 +3226,6 @@ var RECORDS_ERROR_CODES = [
|
|
|
3226
3226
|
"secret-unavailable",
|
|
3227
3227
|
"invalid-record",
|
|
3228
3228
|
"declaration-refused",
|
|
3229
|
-
"adoption-pending",
|
|
3230
3229
|
"no-caller",
|
|
3231
3230
|
"batch-too-large"
|
|
3232
3231
|
];
|
|
@@ -3324,13 +3323,6 @@ var DeclarationRefusedError = class extends RecordsError {
|
|
|
3324
3323
|
this.name = "DeclarationRefusedError";
|
|
3325
3324
|
}
|
|
3326
3325
|
};
|
|
3327
|
-
/** A kind is empty while the legacy table it adopts from still holds rows. */
|
|
3328
|
-
var AdoptionPendingError = class extends RecordsError {
|
|
3329
|
-
constructor(detail) {
|
|
3330
|
-
super("adoption-pending", detail);
|
|
3331
|
-
this.name = "AdoptionPendingError";
|
|
3332
|
-
}
|
|
3333
|
-
};
|
|
3334
3326
|
var NoCallerError = class extends RecordsError {
|
|
3335
3327
|
constructor(detail) {
|
|
3336
3328
|
super("no-caller", detail);
|
|
@@ -3356,7 +3348,6 @@ var FACTORIES = {
|
|
|
3356
3348
|
"secret-unavailable": (d) => new RecordSecretUnavailableError(d),
|
|
3357
3349
|
"invalid-record": (d) => new InvalidRecordError(d),
|
|
3358
3350
|
"declaration-refused": (d) => new DeclarationRefusedError(d),
|
|
3359
|
-
"adoption-pending": (d) => new AdoptionPendingError(d),
|
|
3360
3351
|
"no-caller": (d) => new NoCallerError(d),
|
|
3361
3352
|
"batch-too-large": (d) => new BatchTooLargeError(d)
|
|
3362
3353
|
};
|
|
@@ -3668,7 +3659,13 @@ var RecordKindDeclarationSchema = zod.z.object({
|
|
|
3668
3659
|
secretPaths: zod.z.array(zod.z.string().min(1)).default([]),
|
|
3669
3660
|
/** The id key of each array that carries a secret (`{ headers: 'name' }`). */
|
|
3670
3661
|
secretArrayKeys: zod.z.record(zod.z.string(), zod.z.string()).default({}),
|
|
3671
|
-
/**
|
|
3662
|
+
/**
|
|
3663
|
+
* RETIRED (D900): the legacy table a kind adopted from during the records
|
|
3664
|
+
* migration. Nothing declares it any more and nothing reads it; the schema
|
|
3665
|
+
* still ACCEPTS it because the catalog rows the migration wrote carry it
|
|
3666
|
+
* (an orphaned kind is never redeclared) and an addon built before the
|
|
3667
|
+
* removal still sends it. Never set it.
|
|
3668
|
+
*/
|
|
3672
3669
|
adoptsFrom: zod.z.string().min(1).optional(),
|
|
3673
3670
|
/** Kinds that must agree through `transact` sit in one file under one family name. */
|
|
3674
3671
|
transactFamily: zod.z.string().min(1).optional(),
|
|
@@ -3743,7 +3740,6 @@ function defineRecordKinds(specs) {
|
|
|
3743
3740
|
maxDataBytes: spec.maxDataBytes,
|
|
3744
3741
|
secretPaths: [...secretPaths],
|
|
3745
3742
|
secretArrayKeys: spec.secretArrayKeys === void 0 ? void 0 : { ...spec.secretArrayKeys },
|
|
3746
|
-
adoptsFrom: spec.adoptsFrom,
|
|
3747
3743
|
transactFamily: spec.transactFamily,
|
|
3748
3744
|
entry: spec.entry === void 0 ? void 0 : {
|
|
3749
3745
|
title: spec.entry.title,
|
|
@@ -4084,10 +4080,7 @@ function createRecordsAccess(options) {
|
|
|
4084
4080
|
return delegate;
|
|
4085
4081
|
},
|
|
4086
4082
|
async declare(kinds) {
|
|
4087
|
-
|
|
4088
|
-
const pending = Object.entries(result.kinds).filter((entry) => entry[1].adoptionPending !== null);
|
|
4089
|
-
if (pending.length > 0) throw new AdoptionPendingError(`${pending.map(([name, r]) => r.adoptionPending === null ? name : `${name} (legacy table "${r.adoptionPending.legacyTable}" holds ${r.adoptionPending.legacyRows} rows)`).join(", ")}. Stop the addon and run scripts/hub/records-adopt.ts --copy --apply before starting this build`);
|
|
4090
|
-
return result.kinds;
|
|
4083
|
+
return (await call(() => options.transport.declareKinds({ kinds: { ...declarationsOf(kinds) } }))).kinds;
|
|
4091
4084
|
},
|
|
4092
4085
|
kind(definition) {
|
|
4093
4086
|
const existing = handles.get(definition);
|
|
@@ -4142,7 +4135,6 @@ function defineEntryKind(name, spec) {
|
|
|
4142
4135
|
...spec.database === void 0 ? {} : { database: spec.database },
|
|
4143
4136
|
...spec.indexes === void 0 ? {} : { indexes: spec.indexes },
|
|
4144
4137
|
...spec.secretArrayKeys === void 0 ? {} : { secretArrayKeys: spec.secretArrayKeys },
|
|
4145
|
-
...spec.adoptsFrom === void 0 ? {} : { adoptsFrom: spec.adoptsFrom },
|
|
4146
4138
|
entry: {
|
|
4147
4139
|
title: spec.title,
|
|
4148
4140
|
...spec.nameField === void 0 ? {} : { nameField: spec.nameField }
|
|
@@ -4152,49 +4144,6 @@ function defineEntryKind(name, spec) {
|
|
|
4152
4144
|
return defined;
|
|
4153
4145
|
}
|
|
4154
4146
|
//#endregion
|
|
4155
|
-
//#region src/records/settings-brokers-adopts-from.ts
|
|
4156
|
-
/**
|
|
4157
|
-
* Legacy source for broker entry adoption (B2): brokers live in addon-settings
|
|
4158
|
-
* as one row `<addonId>.brokers` whose value is an array until records-adopt
|
|
4159
|
-
* copies them into the entry kind.
|
|
4160
|
-
*/
|
|
4161
|
-
var SETTINGS_BROKERS_ADOPTS_PREFIX = "@settings-brokers/";
|
|
4162
|
-
/** The `adoptsFrom` value for an addon's broker entry kind. */
|
|
4163
|
-
function settingsBrokersAdoptsFrom(addonId) {
|
|
4164
|
-
return `${SETTINGS_BROKERS_ADOPTS_PREFIX}${addonId}`;
|
|
4165
|
-
}
|
|
4166
|
-
/** When non-null, `from` names an addon-settings brokers blob, not a SQL table. */
|
|
4167
|
-
function parseSettingsBrokersAdoptsFrom(from) {
|
|
4168
|
-
if (!from.startsWith("@settings-brokers/")) return null;
|
|
4169
|
-
const addonId = from.slice(18);
|
|
4170
|
-
return addonId.length > 0 ? addonId : null;
|
|
4171
|
-
}
|
|
4172
|
-
//#endregion
|
|
4173
|
-
//#region src/records/settings-array-adopts-from.ts
|
|
4174
|
-
/**
|
|
4175
|
-
* Legacy source for entry adoption (B3): a list stored under addon-settings
|
|
4176
|
-
* `<addonId>.<key>` until records-adopt copies rows into the entry kind.
|
|
4177
|
-
*/
|
|
4178
|
-
var SETTINGS_ARRAY_ADOPTS_PREFIX = "@settings-array/";
|
|
4179
|
-
/** The `adoptsFrom` value for an addon-settings array field. */
|
|
4180
|
-
function settingsArrayAdoptsFrom(addonId, settingsKey) {
|
|
4181
|
-
return `${SETTINGS_ARRAY_ADOPTS_PREFIX}${addonId}/${settingsKey}`;
|
|
4182
|
-
}
|
|
4183
|
-
/** When non-null, `from` names an addon-settings array blob, not a SQL table. */
|
|
4184
|
-
function parseSettingsArrayAdoptsFrom(from) {
|
|
4185
|
-
if (!from.startsWith("@settings-array/")) return null;
|
|
4186
|
-
const rest = from.slice(16);
|
|
4187
|
-
const slash = rest.indexOf("/");
|
|
4188
|
-
if (slash <= 0 || slash >= rest.length - 1) return null;
|
|
4189
|
-
const addonId = rest.slice(0, slash);
|
|
4190
|
-
const settingsKey = rest.slice(slash + 1);
|
|
4191
|
-
if (addonId.length === 0 || settingsKey.length === 0) return null;
|
|
4192
|
-
return {
|
|
4193
|
-
addonId,
|
|
4194
|
-
settingsKey
|
|
4195
|
-
};
|
|
4196
|
-
}
|
|
4197
|
-
//#endregion
|
|
4198
4147
|
//#region src/records/in-memory-records.ts
|
|
4199
4148
|
/**
|
|
4200
4149
|
* In-memory `RecordsAccess` for specs. Kinds are declared by the caller.
|
|
@@ -7561,12 +7510,6 @@ Object.defineProperty(exports, "AUDIO_CHUNK_FORMATS", {
|
|
|
7561
7510
|
return AUDIO_CHUNK_FORMATS;
|
|
7562
7511
|
}
|
|
7563
7512
|
});
|
|
7564
|
-
Object.defineProperty(exports, "AdoptionPendingError", {
|
|
7565
|
-
enumerable: true,
|
|
7566
|
-
get: function() {
|
|
7567
|
-
return AdoptionPendingError;
|
|
7568
|
-
}
|
|
7569
|
-
});
|
|
7570
7513
|
Object.defineProperty(exports, "AudioChunkFormatSchema", {
|
|
7571
7514
|
enumerable: true,
|
|
7572
7515
|
get: function() {
|
|
@@ -8083,18 +8026,6 @@ Object.defineProperty(exports, "SECRET_REF_SCHEME", {
|
|
|
8083
8026
|
return SECRET_REF_SCHEME;
|
|
8084
8027
|
}
|
|
8085
8028
|
});
|
|
8086
|
-
Object.defineProperty(exports, "SETTINGS_ARRAY_ADOPTS_PREFIX", {
|
|
8087
|
-
enumerable: true,
|
|
8088
|
-
get: function() {
|
|
8089
|
-
return SETTINGS_ARRAY_ADOPTS_PREFIX;
|
|
8090
|
-
}
|
|
8091
|
-
});
|
|
8092
|
-
Object.defineProperty(exports, "SETTINGS_BROKERS_ADOPTS_PREFIX", {
|
|
8093
|
-
enumerable: true,
|
|
8094
|
-
get: function() {
|
|
8095
|
-
return SETTINGS_BROKERS_ADOPTS_PREFIX;
|
|
8096
|
-
}
|
|
8097
|
-
});
|
|
8098
8029
|
Object.defineProperty(exports, "SHARE_VIEW_KINDS", {
|
|
8099
8030
|
enumerable: true,
|
|
8100
8031
|
get: function() {
|
|
@@ -8677,18 +8608,6 @@ Object.defineProperty(exports, "parseSecretStatePath", {
|
|
|
8677
8608
|
return parseSecretStatePath;
|
|
8678
8609
|
}
|
|
8679
8610
|
});
|
|
8680
|
-
Object.defineProperty(exports, "parseSettingsArrayAdoptsFrom", {
|
|
8681
|
-
enumerable: true,
|
|
8682
|
-
get: function() {
|
|
8683
|
-
return parseSettingsArrayAdoptsFrom;
|
|
8684
|
-
}
|
|
8685
|
-
});
|
|
8686
|
-
Object.defineProperty(exports, "parseSettingsBrokersAdoptsFrom", {
|
|
8687
|
-
enumerable: true,
|
|
8688
|
-
get: function() {
|
|
8689
|
-
return parseSettingsBrokersAdoptsFrom;
|
|
8690
|
-
}
|
|
8691
|
-
});
|
|
8692
8611
|
Object.defineProperty(exports, "readErrorI18n", {
|
|
8693
8612
|
enumerable: true,
|
|
8694
8613
|
get: function() {
|
|
@@ -8803,18 +8722,6 @@ Object.defineProperty(exports, "selectAssignedProfileSlots", {
|
|
|
8803
8722
|
return selectAssignedProfileSlots;
|
|
8804
8723
|
}
|
|
8805
8724
|
});
|
|
8806
|
-
Object.defineProperty(exports, "settingsArrayAdoptsFrom", {
|
|
8807
|
-
enumerable: true,
|
|
8808
|
-
get: function() {
|
|
8809
|
-
return settingsArrayAdoptsFrom;
|
|
8810
|
-
}
|
|
8811
|
-
});
|
|
8812
|
-
Object.defineProperty(exports, "settingsBrokersAdoptsFrom", {
|
|
8813
|
-
enumerable: true,
|
|
8814
|
-
get: function() {
|
|
8815
|
-
return settingsBrokersAdoptsFrom;
|
|
8816
|
-
}
|
|
8817
|
-
});
|
|
8818
8725
|
Object.defineProperty(exports, "shortSecretRefHash", {
|
|
8819
8726
|
enumerable: true,
|
|
8820
8727
|
get: function() {
|
package/package.json
CHANGED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Legacy source for entry adoption (B3): a list stored under addon-settings
|
|
3
|
-
* `<addonId>.<key>` until records-adopt copies rows into the entry kind.
|
|
4
|
-
*/
|
|
5
|
-
export declare const SETTINGS_ARRAY_ADOPTS_PREFIX = "@settings-array/";
|
|
6
|
-
/** The `adoptsFrom` value for an addon-settings array field. */
|
|
7
|
-
export declare function settingsArrayAdoptsFrom(addonId: string, settingsKey: string): string;
|
|
8
|
-
/** When non-null, `from` names an addon-settings array blob, not a SQL table. */
|
|
9
|
-
export declare function parseSettingsArrayAdoptsFrom(from: string): {
|
|
10
|
-
readonly addonId: string;
|
|
11
|
-
readonly settingsKey: string;
|
|
12
|
-
} | null;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Legacy source for broker entry adoption (B2): brokers live in addon-settings
|
|
3
|
-
* as one row `<addonId>.brokers` whose value is an array until records-adopt
|
|
4
|
-
* copies them into the entry kind.
|
|
5
|
-
*/
|
|
6
|
-
export declare const SETTINGS_BROKERS_ADOPTS_PREFIX = "@settings-brokers/";
|
|
7
|
-
/** The `adoptsFrom` value for an addon's broker entry kind. */
|
|
8
|
-
export declare function settingsBrokersAdoptsFrom(addonId: string): string;
|
|
9
|
-
/** When non-null, `from` names an addon-settings brokers blob, not a SQL table. */
|
|
10
|
-
export declare function parseSettingsBrokersAdoptsFrom(from: string): string | null;
|