@absolutejs/absolute 0.20.0-beta.20 → 0.20.0-beta.21
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/angular/browser.js +15 -1
- package/dist/angular/browser.js.map +3 -3
- package/dist/angular/components/core/streamingSlotRegistrar.js +1 -1
- package/dist/angular/components/core/streamingSlotRegistry.js +2 -2
- package/dist/build.js +15 -1
- package/dist/build.js.map +3 -3
- package/dist/cli/index.js +13 -3
- package/dist/index.js +17 -2
- package/dist/index.js.map +4 -4
- package/dist/mobile/index.js +9 -1
- package/dist/mobile/index.js.map +4 -4
- package/dist/src/mobile/deviceCapabilities.d.ts +1 -1
- package/dist/src/utils/imageProcessing.d.ts +3 -0
- package/package.json +11 -10
package/dist/cli/index.js
CHANGED
|
@@ -6948,6 +6948,8 @@ var init_deviceCapabilities = __esm(() => {
|
|
|
6948
6948
|
ANDROID_PERMISSION_PATTERN = /^android\.permission\.[A-Z][A-Z0-9_]*$/u;
|
|
6949
6949
|
IOS_USAGE_DESCRIPTIONS = new Set([
|
|
6950
6950
|
"camera",
|
|
6951
|
+
"location-always",
|
|
6952
|
+
"location-when-in-use",
|
|
6951
6953
|
"photo-library",
|
|
6952
6954
|
"photo-library-add"
|
|
6953
6955
|
]);
|
|
@@ -16498,6 +16500,10 @@ var START_MARKER2 = "<!-- absolutejs:device-capabilities:start -->", END_MARKER2
|
|
|
16498
16500
|
return `${appName} uses your camera when you choose to take a photo.`;
|
|
16499
16501
|
if (purpose === "photo-library")
|
|
16500
16502
|
return `${appName} accesses your photo library only for photo actions you choose.`;
|
|
16503
|
+
if (purpose === "location-when-in-use")
|
|
16504
|
+
return `${appName} uses your location only while you are using the app and request a location-based action.`;
|
|
16505
|
+
if (purpose === "location-always")
|
|
16506
|
+
return `${appName} does not track location in the background; this description supports the foreground location provider required by the native runtime.`;
|
|
16501
16507
|
return `${appName} adds to your photo library only for photo actions you choose.`;
|
|
16502
16508
|
}, configureIos2 = async (config, plan) => {
|
|
16503
16509
|
const path = join47(config.nativeProjectDirectory, "ios/App/App/Info.plist");
|
|
@@ -16538,6 +16544,8 @@ var init_nativeDeviceCapabilities = __esm(() => {
|
|
|
16538
16544
|
init_deviceCapabilities();
|
|
16539
16545
|
IOS_KEYS = {
|
|
16540
16546
|
camera: "NSCameraUsageDescription",
|
|
16547
|
+
"location-always": "NSLocationAlwaysAndWhenInUseUsageDescription",
|
|
16548
|
+
"location-when-in-use": "NSLocationWhenInUseUsageDescription",
|
|
16541
16549
|
"photo-library": "NSPhotoLibraryUsageDescription",
|
|
16542
16550
|
"photo-library-add": "NSPhotoLibraryAddUsageDescription"
|
|
16543
16551
|
};
|
|
@@ -17446,6 +17454,8 @@ var init_releaseDoctor = __esm(() => {
|
|
|
17446
17454
|
RELEASE_ASSET_EXTENSIONS = new Set([".html", ".js", ".mjs"]);
|
|
17447
17455
|
IOS_USAGE_KEYS = {
|
|
17448
17456
|
camera: "NSCameraUsageDescription",
|
|
17457
|
+
"location-always": "NSLocationAlwaysAndWhenInUseUsageDescription",
|
|
17458
|
+
"location-when-in-use": "NSLocationWhenInUseUsageDescription",
|
|
17449
17459
|
"photo-library": "NSPhotoLibraryUsageDescription",
|
|
17450
17460
|
"photo-library-add": "NSPhotoLibraryAddUsageDescription"
|
|
17451
17461
|
};
|
|
@@ -18929,11 +18939,11 @@ var init_mobile = __esm(() => {
|
|
|
18929
18939
|
"@capacitor/cli@8.5.0",
|
|
18930
18940
|
"@capacitor/android@8.5.0",
|
|
18931
18941
|
"@capacitor/ios@8.5.0",
|
|
18932
|
-
"@absolutejs/devices@0.
|
|
18933
|
-
"@absolutejs/devices-capacitor@0.
|
|
18942
|
+
"@absolutejs/devices@0.3.0",
|
|
18943
|
+
"@absolutejs/devices-capacitor@0.4.0"
|
|
18934
18944
|
];
|
|
18935
18945
|
CAPACITOR_SYNC_PACKAGE_SPECS = [
|
|
18936
|
-
"@absolutejs/sync-capacitor@0.9.
|
|
18946
|
+
"@absolutejs/sync-capacitor@0.9.1",
|
|
18937
18947
|
"@capacitor-community/sqlite@8.1.1"
|
|
18938
18948
|
];
|
|
18939
18949
|
});
|
package/dist/index.js
CHANGED
|
@@ -11834,6 +11834,20 @@ var DEFAULT_DEVICE_SIZES, DEFAULT_IMAGE_SIZES, DEFAULT_QUALITY, OPTIMIZATION_END
|
|
|
11834
11834
|
return "webp";
|
|
11835
11835
|
}
|
|
11836
11836
|
return "jpeg";
|
|
11837
|
+
}, sniffImageMime = (buffer) => {
|
|
11838
|
+
if (buffer.length < 12)
|
|
11839
|
+
return null;
|
|
11840
|
+
if (buffer[0] === 137 && buffer[1] === 80 && buffer[2] === 78)
|
|
11841
|
+
return "image/png";
|
|
11842
|
+
if (buffer[0] === 255 && buffer[1] === 216)
|
|
11843
|
+
return "image/jpeg";
|
|
11844
|
+
if (buffer[0] === 71 && buffer[1] === 73 && buffer[2] === 70)
|
|
11845
|
+
return "image/gif";
|
|
11846
|
+
if (buffer.toString("ascii", 0, 4) === "RIFF" && buffer.toString("ascii", 8, 12) === "WEBP")
|
|
11847
|
+
return "image/webp";
|
|
11848
|
+
if (buffer.toString("ascii", 4, 12) === "ftypavif")
|
|
11849
|
+
return "image/avif";
|
|
11850
|
+
return null;
|
|
11837
11851
|
}, AVIF_QUALITY_OFFSET = 20, AVIF_EFFORT = 3, PNG_COMPRESSION_LEVEL = 9, optimizeWithBunImage = async (buffer, width, quality, format) => {
|
|
11838
11852
|
const pipeline = new Bun.Image(buffer).resize(width, undefined, {
|
|
11839
11853
|
withoutEnlargement: true
|
|
@@ -30465,7 +30479,7 @@ var DEFAULT_CACHE_TTL_SECONDS = 60, MS_PER_SECOND = 1000, MAX_QUALITY = 100, avi
|
|
|
30465
30479
|
const { isRemote, resolvedPath } = security;
|
|
30466
30480
|
const acceptHeader = request.headers.get("Accept") ?? "";
|
|
30467
30481
|
const format = negotiateFormat(acceptHeader, configuredFormats);
|
|
30468
|
-
|
|
30482
|
+
let mime = formatToMime(format);
|
|
30469
30483
|
const cacheKey2 = getCacheKey(url, width, quality, format);
|
|
30470
30484
|
const cached = readFromCache(cacheDir, cacheKey2);
|
|
30471
30485
|
if (cached && !isCacheStale(cached.meta)) {
|
|
@@ -30505,6 +30519,7 @@ var DEFAULT_CACHE_TTL_SECONDS = 60, MS_PER_SECOND = 1000, MAX_QUALITY = 100, avi
|
|
|
30505
30519
|
optimizedBuffer = await optimizeImage(sourceBuffer, width, quality, format);
|
|
30506
30520
|
} catch {
|
|
30507
30521
|
optimizedBuffer = sourceBuffer;
|
|
30522
|
+
mime = sniffImageMime(sourceBuffer) ?? mime;
|
|
30508
30523
|
}
|
|
30509
30524
|
const etag = `"${cacheKey2}"`;
|
|
30510
30525
|
const meta = {
|
|
@@ -40419,5 +40434,5 @@ export {
|
|
|
40419
40434
|
ANGULAR_INIT_TIMEOUT_MS
|
|
40420
40435
|
};
|
|
40421
40436
|
|
|
40422
|
-
//# debugId=
|
|
40437
|
+
//# debugId=FE6F812740A4A80564756E2164756E21
|
|
40423
40438
|
//# sourceMappingURL=index.js.map
|