feat: snippet with term ctrl (#380 #382)

This commit is contained in:
lollipopkit
2024-06-10 21:08:33 +08:00
parent edceb5900e
commit 490d71f8c9
7 changed files with 171 additions and 38 deletions

View File

@@ -126,7 +126,7 @@ void _onTapMoreBtns(
if (snippets == null || snippets.isEmpty) return;
final snippet = snippets.firstOrNull;
if (snippet == null) return;
final fmted = snippet.fmtWith(spi);
final fmted = snippet.fmtWithSpi(spi);
final sure = await context.showRoundDialog<bool>(
title: l10n.attention,
child: SingleChildScrollView(
@@ -141,7 +141,7 @@ void _onTapMoreBtns(
],
);
if (sure != true) return;
AppRoutes.ssh(spi: spi, initCmd: fmted).checkGo(
AppRoutes.ssh(spi: spi, initSnippet: snippet).checkGo(
context: context,
check: () => _checkClient(context, spi.id),
);