メインコンテンツにジャンプ

Getting Started

GitHub

AIアシストされたセットアップを使用してプラグインをインストールできます。AIツールにCapgoスキルを追加するには、以下のコマンドを実行してください。

ターミナル画面
npx skills add https://github.com/Cap-go/capgo-skills --skill capacitor-plugins

次に、以下のプロンプトを使用してください。

Use the `capacitor-plugins` skill from `Cap-go/capgo-skills` to install the `@capgo/capacitor-textinteraction` plugin in my project.

Manualセットアップを使用する場合は、以下のコマンドを実行してプラグインをインストールし、以下のプラットフォーム固有の指示に従ってください。

ターミナル画面
bun add @capgo/capacitor-textinteraction
bunx cap sync
import { TextInteraction } from '@capgo/capacitor-textinteraction';

Capacitor WebView でテキストの選択を有効/無効にする

⚠️ テキストの選択を無効にすると、テキスト入力コントロールがすべて動作しなくなります。 使用する場合は、必要に応じて有効にすることをお勧めします。

iOS 限定

import { TextInteraction } from '@capgo/capacitor-textinteraction';
await TextInteraction.toggle({} as TextInteractionOptions);
export interface TextInteractionOptions {
/**
* Whether text interaction should be enabled or disabled. Disabling hides the
* magnifier lens reintroduced with iOS 15.
*/
enabled: boolean;
}
export interface TextInteractionResult {
/**
* `true` when the platform supports toggling text interaction (iOS >= 14.5), otherwise `false`.
*/
success: boolean;
/**
* Get the native Capacitor plugin version
*
* @returns {Promise<{ id: string }>} an Promise with version for this device
* @throws An error if the something went wrong
*/
getPluginVersion(): Promise<{ version: string }>;
}

このページはプラグインの src/definitions.ts. 公開 API がアップストリームで変更された場合に再度同期を実行してください。

Getting Started から続けてください

「Getting Started から続けてください」セクション

あなたが使用している場合 Getting Started ダッシュボードと API の作業を計画する場合、接続してください Using @capgo/capacitor-textinteraction for the native capability in Using @capgo/capacitor-textinteraction API アシア、読にため for the implementation detail in API アシア、読にため バーター for the implementation detail in バーター API カース for the implementation detail in API カース, 。 設子 for the implementation detail in 設子