@dereekb/firebase 13.6.11 → 13.6.13

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/index.cjs.js CHANGED
@@ -10579,7 +10579,7 @@ function _define_property$f(obj, key, value) {
10579
10579
  * ArkType validator for {@link ScheduledFunctionDevelopmentFirebaseFunctionParams}.
10580
10580
  */ var scheduledFunctionDevelopmentFirebaseFunctionParamsType = arktype.type({
10581
10581
  type: "'list' | 'run'",
10582
- 'run?': 'string'
10582
+ 'run?': model.clearable('string')
10583
10583
  });
10584
10584
  /**
10585
10585
  * Entry in the list of available scheduled functions returned by the development endpoint.
@@ -10645,7 +10645,7 @@ function _define_property$f(obj, key, value) {
10645
10645
  /**
10646
10646
  * ArkType validator for {@link InferredTargetModelParams}.
10647
10647
  */ var inferredTargetModelParamsType = arktype.type({
10648
- 'key?': firestoreModelKeyType
10648
+ 'key?': model.clearable(firestoreModelKeyType)
10649
10649
  });
10650
10650
  /**
10651
10651
  * ArkType validator for {@link TargetModelIdParams} — requires a valid document ID.
@@ -10655,7 +10655,7 @@ function _define_property$f(obj, key, value) {
10655
10655
  /**
10656
10656
  * ArkType validator for {@link InferredTargetModelIdParams}.
10657
10657
  */ var inferredTargetModelIdParamsType = arktype.type({
10658
- 'key?': firestoreModelIdType
10658
+ 'key?': model.clearable(firestoreModelIdType)
10659
10659
  });
10660
10660
 
10661
10661
  function _assert_this_initialized$5(self) {
@@ -14175,7 +14175,7 @@ var createNotificationBoxParamsType = arktype.type({
14175
14175
  model: firestoreModelKeyType
14176
14176
  });
14177
14177
  var initializeNotificationModelParamsType = targetModelParamsType.merge({
14178
- 'throwErrorIfAlreadyInitialized?': 'boolean'
14178
+ 'throwErrorIfAlreadyInitialized?': model.clearable('boolean')
14179
14179
  });
14180
14180
  var initializeAllApplicableNotificationBoxesParamsType = arktype.type({});
14181
14181
  var initializeAllApplicableNotificationSummariesParamsType = arktype.type({});
package/index.esm.js CHANGED
@@ -2,7 +2,7 @@ import { increment, arrayRemove, arrayUnion, onSnapshot, getDoc, deleteDoc, setD
2
2
  import { cachedGetter, mergeModifiers, asArray, filterUndefinedValues, objectHasNoKeys, filterFalsyAndEmptyValues, build, wrapUseAsyncFunction, runAsyncTasksForValues, filterMaybeArrayValues, performMakeLoop, makeWithFactory, useAsync, MAP_IDENTITY, toModelFieldConversions, makeModelMapFunctions, modifyModelMapFunctions, assignValuesToPOJOFunction, KeyValueTypleValueFilter, asObjectCopyFactory, transformStringFunctionConfig, transformStringFunction, passThrough, filterUniqueTransform, unique, transformNumberFunction, sortValuesFunctionOrMapIdentityWithSortRef, toModelMapFunctions, isEqualToValueDecisionFunction, filterFromPOJOFunction, mapObjectMap, copyObject, modelFieldMapFunctions, filterNullAndUndefinedValues, dateFromDateOrTimeSecondsNumber, unixDateTimeSecondsNumberFromDate, isDate, bitwiseSetDencoder, sortAscendingIndexNumberRefFunction, latLngStringFunction, mapObjectMapFunction, filterEmptyArrayValues, filterUniqueFunction, isMapIdentityFunction, chainMapSameFunctions, DEFAULT_LAT_LNG_STRING_VALUE, pushItemOrArrayItemsIntoArray, separateValues, convertToArray, UTF_PRIVATE_USAGE_AREA_START, UTF_8_START_CHARACTER, mergeArraysIntoArray, lastValue, flattenArrayOrValueArray, allowValueOnceFilter, asGetter, getValueFromGetter, mapIdentityFunction, performTasksFromFactoryInParallelFunction, performAsyncTasks, batch, flattenArray, calculateExpirationDate, groupValues, stringContains, forEachInIterable, arrayToObject, takeFront, isOddNumber, objectToMap, ServerErrorResponse, toReadableError, capitalizeFirstLetter, lowercaseFirstLetter, toRelativeSlashPathStartType, mappedUseFunction, iterableToArray, setContainsAllValues, usePromise, slashPathFactory, errorMessageContainsString, bitwiseObjectDencoder, mergeObjectsFunction, mergeObjects, forEachKeyValue, updateMaybeValue, UNSET_INDEX_NUMBER, ModelRelationUtility, filterKeysOnPOJOFunction, areEqualPOJOValuesUsingPojoFilter, filterOnlyUndefinedValues, makeModelMap, isThrottled, MS_IN_HOUR, multiValueMapBuilder, mergeSlashPaths, slashPathDetails, toAbsoluteSlashPathStartType, SLASH_PATH_FILE_TYPE_SEPARATOR, slashPathPathMatcher, decisionFunction, slashPathSubPathMatcher } from '@dereekb/util';
3
3
  import { filterMaybe, lazyFrom, itemAccumulator, ItemPageIterator, mappedPageItemIteration } from '@dereekb/rxjs';
4
4
  import { map, from, EMPTY, tap, combineLatest, of, Subject, filter, exhaustMap, Observable, switchMap, timer, skip, shareReplay } from 'rxjs';
5
- import { UNKNOWN_WEBSITE_LINK_TYPE, encodeWebsiteFileLinkToWebsiteLinkEncodedData, decodeWebsiteLinkEncodedDataToWebsiteFileLink, AbstractModelPermissionService, grantedRoleMapReader, noAccessRoleMap, fullAccessRoleMap, clearable, e164PhoneNumberType, ARKTYPE_DATE_DTO_TYPE } from '@dereekb/model';
5
+ import { UNKNOWN_WEBSITE_LINK_TYPE, encodeWebsiteFileLinkToWebsiteLinkEncodedData, decodeWebsiteLinkEncodedDataToWebsiteFileLink, clearable, AbstractModelPermissionService, grantedRoleMapReader, noAccessRoleMap, fullAccessRoleMap, e164PhoneNumberType, ARKTYPE_DATE_DTO_TYPE } from '@dereekb/model';
6
6
  import { toISODateString, toJsDate, formatToISO8601DateString, isSameDate, dateRange, sortByDateFunction, yearWeekCode, UNKNOWN_YEAR_WEEK_CODE } from '@dereekb/date';
7
7
  import { httpsCallable } from 'firebase/functions';
8
8
  import { getMetadata, ref, deleteObject, uploadBytesResumable, getBlob, getBytes, uploadString, uploadBytes, updateMetadata, getDownloadURL, list } from 'firebase/storage';
@@ -10577,7 +10577,7 @@ function _define_property$f(obj, key, value) {
10577
10577
  * ArkType validator for {@link ScheduledFunctionDevelopmentFirebaseFunctionParams}.
10578
10578
  */ var scheduledFunctionDevelopmentFirebaseFunctionParamsType = type({
10579
10579
  type: "'list' | 'run'",
10580
- 'run?': 'string'
10580
+ 'run?': clearable('string')
10581
10581
  });
10582
10582
  /**
10583
10583
  * Entry in the list of available scheduled functions returned by the development endpoint.
@@ -10643,7 +10643,7 @@ function _define_property$f(obj, key, value) {
10643
10643
  /**
10644
10644
  * ArkType validator for {@link InferredTargetModelParams}.
10645
10645
  */ var inferredTargetModelParamsType = type({
10646
- 'key?': firestoreModelKeyType
10646
+ 'key?': clearable(firestoreModelKeyType)
10647
10647
  });
10648
10648
  /**
10649
10649
  * ArkType validator for {@link TargetModelIdParams} — requires a valid document ID.
@@ -10653,7 +10653,7 @@ function _define_property$f(obj, key, value) {
10653
10653
  /**
10654
10654
  * ArkType validator for {@link InferredTargetModelIdParams}.
10655
10655
  */ var inferredTargetModelIdParamsType = type({
10656
- 'key?': firestoreModelIdType
10656
+ 'key?': clearable(firestoreModelIdType)
10657
10657
  });
10658
10658
 
10659
10659
  function _assert_this_initialized$5(self) {
@@ -14173,7 +14173,7 @@ var createNotificationBoxParamsType = type({
14173
14173
  model: firestoreModelKeyType
14174
14174
  });
14175
14175
  var initializeNotificationModelParamsType = targetModelParamsType.merge({
14176
- 'throwErrorIfAlreadyInitialized?': 'boolean'
14176
+ 'throwErrorIfAlreadyInitialized?': clearable('boolean')
14177
14177
  });
14178
14178
  var initializeAllApplicableNotificationBoxesParamsType = type({});
14179
14179
  var initializeAllApplicableNotificationSummariesParamsType = type({});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dereekb/firebase",
3
- "version": "13.6.11",
3
+ "version": "13.6.13",
4
4
  "exports": {
5
5
  "./test": {
6
6
  "module": "./test/index.esm.js",
@@ -17,10 +17,10 @@
17
17
  }
18
18
  },
19
19
  "peerDependencies": {
20
- "@dereekb/util": "13.6.11",
21
- "@dereekb/date": "13.6.11",
22
- "@dereekb/model": "13.6.11",
23
- "@dereekb/rxjs": "13.6.11",
20
+ "@dereekb/util": "13.6.13",
21
+ "@dereekb/date": "13.6.13",
22
+ "@dereekb/model": "13.6.13",
23
+ "@dereekb/rxjs": "13.6.13",
24
24
  "@firebase/rules-unit-testing": "5.0.0",
25
25
  "arktype": "^2.2.0",
26
26
  "date-fns": "^4.0.0",
@@ -1,7 +1,6 @@
1
1
  import { type Observable } from 'rxjs';
2
2
  import { type Destroyable, type Maybe, type Milliseconds } from '@dereekb/util';
3
- import { type FirestoreCollectionType } from '../collection/collection';
4
- import { type FirestoreModelKey } from '../collection/collection';
3
+ import { type FirestoreCollectionType, type FirestoreModelKey } from '../collection/collection';
5
4
  /**
6
5
  * Options for loading a document with cache support.
7
6
  *
@@ -1,7 +1,6 @@
1
1
  import { type Observable } from 'rxjs';
2
2
  import { type Maybe, type Milliseconds } from '@dereekb/util';
3
- import { type FirestoreCollectionType } from '../collection/collection';
4
- import { type FirestoreModelKey } from '../collection/collection';
3
+ import { type FirestoreCollectionType, type FirestoreModelKey } from '../collection/collection';
5
4
  import { type FirestoreContextCacheFactory, type FirestoreCacheEntry, type FirestoreCacheEvent, type FirestoreContextCache } from './cache';
6
5
  /**
7
6
  * Default TTL used by the in-memory cache when no TTL is specified.
@@ -2,10 +2,9 @@ import { type Type } from 'arktype';
2
2
  import { type TargetModelParams, type OnCallCreateModelResult, type FirestoreModelKey } from '../../common';
3
3
  import { type ModelFirebaseCrudFunction, type FirebaseFunctionTypeConfigMap, type ModelFirebaseCrudFunctionConfigMap, type ModelFirebaseFunctionMap, type ModelFirebaseCreateFunction } from '../../client';
4
4
  import { type StorageFileSignedDownloadUrl, type StorageFileTypes } from './storagefile';
5
- import { type StorageFileKey } from './storagefile.id';
5
+ import { type StorageFileKey, type StorageFileId } from './storagefile.id';
6
6
  import { type StorageBucketId, type StoragePath, type StorageSlashPath } from '../../common/storage';
7
7
  import { type ContentDispositionString, type ContentTypeMimeType, type Maybe, type Milliseconds, type UnixDateTimeSecondsNumber } from '@dereekb/util';
8
- import { type StorageFileId } from './storagefile.id';
9
8
  import { type SendNotificationResult } from '../notification/notification.api';
10
9
  /**
11
10
  * Parameters for directly creating a new StorageFile document (no upload initialization).
package/test/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@dereekb/firebase/test",
3
- "version": "13.6.11",
3
+ "version": "13.6.13",
4
4
  "peerDependencies": {
5
- "@dereekb/date": "13.6.11",
6
- "@dereekb/firebase": "13.6.11",
7
- "@dereekb/model": "13.6.11",
8
- "@dereekb/rxjs": "13.6.11",
9
- "@dereekb/util": "13.6.11",
5
+ "@dereekb/date": "13.6.13",
6
+ "@dereekb/firebase": "13.6.13",
7
+ "@dereekb/model": "13.6.13",
8
+ "@dereekb/rxjs": "13.6.13",
9
+ "@dereekb/util": "13.6.13",
10
10
  "@firebase/rules-unit-testing": "5.0.0",
11
11
  "date-fns": "^4.0.0",
12
12
  "firebase": "^12.0.0",