분류, 패키지 및 저장소 검색

keyboard_emoji_picker 표지
패키지 상세v1.0.3

keyboard_emoji_picker

기기의 키보드를 사용하여 이모티콘을 선택하는 Flutter 플러그인입니다.

iOS
30일 다운로드
1.2천
좋아요
31
Pub 점수
150

패키지 설치

flutter pub add keyboard_emoji_picker

패키지 개요

공개 정보를 바탕으로 생성한 선택 가이드입니다.

사용자가 장치의 네이티브 키보드를 통해 직접 이모지를 선택할 수 있도록 해주는 플러터 플러그인입니다. iOS 키보드와 원활하게 통합되어 입력 방법을 전환하지 않고도 부드럽게 이모지를 선택할 수 있습니다. 이 패키지는 메시징 및 텍스트 입력 인터페이스에서 사용자 경험을 향상시키며, 이모지에 빠르게 접근할 수 있도록 합니다. 가볍고 iOS 전용으로 설계되어 플랫폼 고유의 키보드 기능을 활용합니다. 직관적인 이모지 상호작용이 필요한 앱에 적합합니다.

사용 사례

  • 메시징 앱
  • 소셜 미디어 플랫폼
  • 댓글 섹션
  • 사용자 프로필 설명
  • 인터랙티브 채팅 인터페이스

주요 기능

  • 네이티브 iOS 키보드 통합
  • 무결점 이모티콘 선택
  • 경량 구현
  • 플랫폼별 최적화
  • Flutter pub로 간편한 설정

적합한 대상

  • iOS 중심의 Flutter 앱
  • 대량의 텍스트 입력이 필요한 앱
  • 감정이 풍부한 소통 도구
  • 간단한 이모지 선택기 필요
  • 네이티브 UX를 우선시하는 개발자

고려 사항

  • iOS 전용
  • Android 지원 없음
  • 장치 키보드 동작에 의존합니다
  • iOS 버전 간 테스트가 필요할 수 있습니다
  • 최소한의 사용자 정의 옵션

원본 README

연결된 소스 저장소의 README 원문 스냅샷입니다. 최신 내용은 저장소에서 확인하세요.

The keyboard_emoji_picker package provides a simple way to use the device's native emoji keyboard to pick an emoji. It's currently supported on iOS only. However, adding support for Android is something I'd like to do in the future (if you'd like to help, please let me know).

Demo

Usage

To use KeyboardEmojiPicker, you need to have a KeyboardEmojiPickerWrapper widget somewhere in your widget tree. This widget will create a hidden input field in order to make opening the keyboard possible.

import 'package:keyboard_emoji_picker/keyboard_emoji_picker.dart';

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    // While this example wraps [MaterialApp], you don't have to.
    // You can put it wherever you want to use the picker.
    return KeyboardEmojiPickerWrapper(
      child: MaterialApp(
        title: 'My App',
        home: MyHomePage(),
      ),
    );
  }
}
Checking if the keyboard is available

Since the package uses the device's keyboard, it's not always available. For example, if the user has disabled the emoji keyboard, it won't open and will throw a NoEmojiKeyboardFound exception.

To check if the keyboard is available, you can use the checkHasEmojiKeyboard method.

final hasEmojiKeyboard = await KeyboardEmojiPicker().checkHasEmojiKeyboard();

if (hasEmojiKeyboard) {
  // Open the keyboard.
} else {
  // Use another way to pick an emoji or show a dialog asking the user to
  // enable the emoji keyboard.
}
Picking an emoji

To pick an emoji, use the pickEmoji method. It will open the keyboard and wait for the user to pick an emoji. If the user closes the keyboard, the method will return null.

It is highly recommended to check if the keyboard is available before calling this method to avoid exceptions.

final emoji = await KeyboardEmojiPicker().pickEmoji();
if (emoji != null) {
  // Do something with the emoji
} else {
  // The emoji picking process was cancelled (usually, the keyboard was closed).
}
Closing the keyboard

Since the plugin uses a different hidden input than Flutter itself, you need to close the keyboard manually. To do so, use the closeKeyboard method.

KeyboardEmojiPicker().closeKeyboard();

Contributing

Contributions are welcome and appreciated! Feel free to open an issue or a pull request!

카테고리

의존성

의존성 목록 1 개

  • plugin_platform_interface^2.0.2

소스 저장소

이 패키지를 사용하는 프로젝트

아직 데이터가 없습니다.