kingkont 0.7.62 → 0.7.63
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/package.json +1 -1
- package/renderer/board.js +7 -0
- package/renderer/generate.js +6 -0
- package/renderer/media.js +10 -0
- package/renderer/settings.js +4 -0
package/package.json
CHANGED
package/renderer/board.js
CHANGED
|
@@ -817,6 +817,13 @@ async function renameBoard(kind, oldName, newName) {
|
|
|
817
817
|
if (kind === 'character') await refreshCharacters();
|
|
818
818
|
else if (kind === 'location') await refreshLocations();
|
|
819
819
|
else await refreshEpisodes();
|
|
820
|
+
// Перезагрузить charactersInfo/locationsInfo чтобы @-mention popup
|
|
821
|
+
// в любом следующем gen-modal'е увидел новое имя.
|
|
822
|
+
if (kind === 'character' && typeof loadAllCharactersInfo === 'function') {
|
|
823
|
+
loadAllCharactersInfo().catch(() => {});
|
|
824
|
+
} else if (kind === 'location' && typeof loadAllLocationsInfo === 'function') {
|
|
825
|
+
loadAllLocationsInfo().catch(() => {});
|
|
826
|
+
}
|
|
820
827
|
// Если был активен — переоткрыть с новым именем
|
|
821
828
|
if (wasActive) {
|
|
822
829
|
const list = kind === 'character' ? await listCharacters(state.filmHandle)
|
package/renderer/generate.js
CHANGED
|
@@ -329,6 +329,12 @@ async function openGenModal(kind) {
|
|
|
329
329
|
syncCharLocRows();
|
|
330
330
|
if (kind === 'audio') { loadVoices(); }
|
|
331
331
|
closeMentionPopup();
|
|
332
|
+
// Освежаем информацию о персонажах/локациях, чтобы недавно добавленные/
|
|
333
|
+
// переименованные ноды появились в @-popup'е. Запускаем в фоне — не
|
|
334
|
+
// блокируем открытие модалки (если что — popup обновится при следующем
|
|
335
|
+
// keystroke; а charactersInfo тогда обновится к моменту следующего typing).
|
|
336
|
+
if (typeof loadAllCharactersInfo === 'function') loadAllCharactersInfo().catch(() => {});
|
|
337
|
+
if (typeof loadAllLocationsInfo === 'function') loadAllLocationsInfo().catch(() => {});
|
|
332
338
|
syncSourceRefRow();
|
|
333
339
|
syncDefaultPromptRow();
|
|
334
340
|
// Если открываем image-генерацию и есть исходная картинка-референс —
|
package/renderer/media.js
CHANGED
|
@@ -732,6 +732,10 @@ async function regenerateInto(node, kind, rawPrompt, opts = {}) {
|
|
|
732
732
|
? { file: opts.sourceRef.file, type: opts.sourceRef.type }
|
|
733
733
|
: (node.generated?.sourceRef || null);
|
|
734
734
|
|
|
735
|
+
// Параметры image/video, выбранные в gen-modal'е, СОХРАНЯЕМ в seedGen —
|
|
736
|
+
// иначе после regenerate node.generated.aspectRatio становится undefined,
|
|
737
|
+
// и в startGenerationJob срабатывает fallback на scene.settings.aspectRatio
|
|
738
|
+
// (по дефолту 9:16) — игнорируя то что юзер выбрал в модалке.
|
|
735
739
|
const seedGen = kind === 'audio'
|
|
736
740
|
? { kind, prompt: resolvedPrompt, rawPrompt, model: modelId, voiceId, voiceName,
|
|
737
741
|
ttsModel: state.ttsModel || node.generated?.ttsModel || 'qwen/qwen3-tts',
|
|
@@ -739,6 +743,12 @@ async function regenerateInto(node, kind, rawPrompt, opts = {}) {
|
|
|
739
743
|
: { kind, prompt: resolvedPrompt, rawPrompt, modelKey, model: modelId,
|
|
740
744
|
refs: refs ? refs.map(r => ({ name: r.name, type: r.type, file: r.file })) : [],
|
|
741
745
|
...(carryoverSourceRef ? { sourceRef: carryoverSourceRef } : {}),
|
|
746
|
+
...(kind === 'image' ? { aspectRatio: state.imageAspect } : {}),
|
|
747
|
+
...(kind === 'video' ? {
|
|
748
|
+
aspectRatio: state.videoAspect,
|
|
749
|
+
duration: state.videoDuration,
|
|
750
|
+
resolution: state.videoResolution,
|
|
751
|
+
} : {}),
|
|
742
752
|
state: 'submitting' };
|
|
743
753
|
|
|
744
754
|
// Для text-ноды сохраняем существующий .md-файл (runTextJob перезапишет
|
package/renderer/settings.js
CHANGED
|
@@ -475,6 +475,10 @@ async function openGenerateForRef(fromNode, clientX, clientY, forceKind) {
|
|
|
475
475
|
state.sourceRef = null;
|
|
476
476
|
$('genPrompt').value = '[@' + nodeRefKey(fromNode) + '] ';
|
|
477
477
|
}
|
|
478
|
+
// Lazy refresh — чтобы свежедобавленные/переименованные ноды
|
|
479
|
+
// персонажей и локаций попали в @-popup сразу после открытия модалки.
|
|
480
|
+
if (typeof loadAllCharactersInfo === 'function') loadAllCharactersInfo().catch(() => {});
|
|
481
|
+
if (typeof loadAllLocationsInfo === 'function') loadAllLocationsInfo().catch(() => {});
|
|
478
482
|
syncSourceRefRow();
|
|
479
483
|
if (typeof syncDefaultPromptRow === 'function') syncDefaultPromptRow();
|
|
480
484
|
|