Skip to content

Commit

Permalink
無音の長さ一括変更するUIの表示をエンジンの能力で切り替えるようにする (#2401)
Browse files Browse the repository at this point in the history
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
Hiroshiba and github-actions[bot] authored Dec 13, 2024
1 parent 7d2ef38 commit 4b06923
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
2 changes: 2 additions & 0 deletions public/howtouse.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,8 @@ GPU をお持ちの方は、音声の生成がずっと速い GPU モードを
- 読み上げの抑揚を変更できます。数値が小さいほど棒読みに近くなります。
- 音量
- 音声の音量を変更できます。数値が大きいほど音が大きくなります。
- 間の長さ
- 文中の無音の長さを変更できます。数値が大きいほど無音時間が長くなります。
- 開始無音・終了無音
- 音声の先頭や末尾の無音の長さを変更できます。数値が大きいほど無音時間が長くなります。

Expand Down
14 changes: 7 additions & 7 deletions src/components/Talk/AudioInfo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ const parameterConfigs = computed<ParameterConfig[]>(() => [
sliderProps: {
modelValue: () => query.value?.speedScale ?? null,
disable: () =>
uiLocked.value || supportedFeatures.value?.adjustSpeedScale === false,
uiLocked.value || !supportedFeatures.value?.adjustSpeedScale,
max: SLIDER_PARAMETERS.SPEED.max,
min: SLIDER_PARAMETERS.SPEED.min,
step: SLIDER_PARAMETERS.SPEED.step,
Expand All @@ -382,7 +382,7 @@ const parameterConfigs = computed<ParameterConfig[]>(() => [
sliderProps: {
modelValue: () => query.value?.pitchScale ?? null,
disable: () =>
uiLocked.value || supportedFeatures.value?.adjustPitchScale === false,
uiLocked.value || !supportedFeatures.value?.adjustPitchScale,
max: SLIDER_PARAMETERS.PITCH.max,
min: SLIDER_PARAMETERS.PITCH.min,
step: SLIDER_PARAMETERS.PITCH.step,
Expand All @@ -400,8 +400,7 @@ const parameterConfigs = computed<ParameterConfig[]>(() => [
sliderProps: {
modelValue: () => query.value?.intonationScale ?? null,
disable: () =>
uiLocked.value ||
supportedFeatures.value?.adjustIntonationScale === false,
uiLocked.value || !supportedFeatures.value?.adjustIntonationScale,
max: SLIDER_PARAMETERS.INTONATION.max,
min: SLIDER_PARAMETERS.INTONATION.min,
step: SLIDER_PARAMETERS.INTONATION.step,
Expand All @@ -420,7 +419,7 @@ const parameterConfigs = computed<ParameterConfig[]>(() => [
sliderProps: {
modelValue: () => query.value?.volumeScale ?? null,
disable: () =>
uiLocked.value || supportedFeatures.value?.adjustVolumeScale === false,
uiLocked.value || !supportedFeatures.value?.adjustVolumeScale,
max: SLIDER_PARAMETERS.VOLUME.max,
min: SLIDER_PARAMETERS.VOLUME.min,
step: SLIDER_PARAMETERS.VOLUME.step,
Expand All @@ -435,10 +434,11 @@ const parameterConfigs = computed<ParameterConfig[]>(() => [
key: "volumeScale",
},
{
label: "文内無音倍率",
label: "間の長さ",
sliderProps: {
modelValue: () => query.value?.pauseLengthScale ?? null,
disable: () => uiLocked.value,
disable: () =>
uiLocked.value || !supportedFeatures.value?.adjustPauseLength,
max: SLIDER_PARAMETERS.PAUSE_LENGTH_SCALE.max,
min: SLIDER_PARAMETERS.PAUSE_LENGTH_SCALE.min,
step: SLIDER_PARAMETERS.PAUSE_LENGTH_SCALE.step,
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions tests/e2e/browser/複数選択/値変更.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ test("複数選択:AudioInfo操作", async ({ page }) => {

for (const parameter of parameters) {
const input = parameter.locator("label input");
if (await input.isDisabled()) continue;
await input.fill("2");
await page.waitForTimeout(100);
}
Expand Down

0 comments on commit 4b06923

Please sign in to comment.