Fix incorrect conversion trim option typings, change release CI to "trusted publishing"

This commit is contained in:
Vanilagy
2025-12-04 16:40:41 +01:00
parent e5aeff89e3
commit 816bb020fb
5 changed files with 19 additions and 16 deletions
+1 -4
View File
@@ -5,6 +5,7 @@ on:
types: [published]
permissions:
id-token: write # Required for OIDC
contents: read
jobs:
@@ -59,10 +60,6 @@ jobs:
- name: Publish Mediabunny to npm
run: npm publish --provenance --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Publish workspace packages to npm
run: npm publish --provenance --access public --workspaces
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
+6 -6
View File
@@ -1,12 +1,12 @@
{
"name": "mediabunny",
"version": "1.25.4",
"version": "1.25.5",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "mediabunny",
"version": "1.25.4",
"version": "1.25.5",
"license": "MPL-2.0",
"workspaces": [
"packages/*"
@@ -7739,9 +7739,9 @@
}
},
"node_modules/mediabunny": {
"version": "1.25.3",
"resolved": "https://registry.npmjs.org/mediabunny/-/mediabunny-1.25.3.tgz",
"integrity": "sha512-+LDXv/kybsElRQCmMlrdbKmPNvegeIyouGeOUzW5DJ8+M56H4G6wyEL2AJ1A45UcOB+U62qJMV7tuFO9S7yA7g==",
"version": "1.25.4",
"resolved": "https://registry.npmjs.org/mediabunny/-/mediabunny-1.25.4.tgz",
"integrity": "sha512-oEMpnAj3fwP6mel84liF7vG58fl0RMC77jS9nmy0UH45nSfZgQqPj06TRQoje1n9hLpz6Dun4+UyCg6x+EKUvw==",
"license": "MPL-2.0",
"peer": true,
"workspaces": [
@@ -12065,7 +12065,7 @@
},
"packages/mp3-encoder": {
"name": "@mediabunny/mp3-encoder",
"version": "1.25.4",
"version": "1.25.5",
"license": "MPL-2.0",
"devDependencies": {
"@types/emscripten": "^1.40.1"
+1 -1
View File
@@ -1,7 +1,7 @@
{
"name": "mediabunny",
"author": "Vanilagy",
"version": "1.25.4",
"version": "1.25.5",
"description": "Pure TypeScript media toolkit for reading, writing, and converting media files, directly in the browser.",
"type": "module",
"workspaces": [
+1 -1
View File
@@ -1,7 +1,7 @@
{
"name": "@mediabunny/mp3-encoder",
"author": "Vanilagy",
"version": "1.25.4",
"version": "1.25.5",
"description": "MP3 encoder extension for Mediabunny, based on LAME.",
"main": "./dist/bundles/mediabunny-mp3-encoder.mjs",
"module": "./dist/bundles/mediabunny-mp3-encoder.mjs",
+10 -4
View File
@@ -82,10 +82,16 @@ export type ConversionOptions = {
/** Options to trim the input file. */
trim?: {
/** The time in the input file in seconds at which the output file should start. Must be less than `end`. */
start: number;
/** The time in the input file in seconds at which the output file should end. Must be greater than `start`. */
end: number;
/**
* The time in the input file in seconds at which the output file should start. Must be less than `end`.
* Defaults to 0 when omitted.
*/
start?: number;
/**
* The time in the input file in seconds at which the output file should end. Must be greater than `start`.
* Defaults to the duration of the input when omitted.
*/
end?: number;
};
/**